Author: Haseeb Ahmad Basil
Updated on: 2016-03-17
Posted on: 2016-03-17
Package: PHP Base64 Encode and Decode
Read this article to learn why I developed a class to implement the base64 algorithm in pure PHP.
When I entered the Software Engineering world, I started with PHP, making dynamic Web sites and Web apps and APIs. But whenever I would look at the complicated codes of other languages like C#, Java, C++ etc., I imagine how can this be implemented in PHP.
Using the functions built-in PHP is not making us extraordinary programmers, although they are very helpful. We should at least know how to implement the most commonly used algorithms.
PHP is a complete programming language. Anything that can be done in C# or Java can be done in PHP. So I gave myself the challenge to implement the Base64 algorithm in PHP. Then I decided to publish it to PHP Classes, so people can learn how easy it is to write complex codes in PHP.
The purpose of this class is more educational than anything else. Please use PHP's built-in base64 algorithm functions in your applications because PHP is unique for being a scripting programming language and executing code that implements these algorithms in pure PHP can be very slow. So it is good that this kind of functions is built-in PHP.
In the end I would like to say that we should all contribute to PHP community in such ways that we can show how algorithms can be implemented in pure PHP, even for functions that PHP already provides as built-in.
You need to be a registered user or login to post a comment
1,538,351 PHP developers registered to the PHP Classes site.
Be One of Us!
Login Immediately with your account on:
No comments were submitted yet.