Stay Current with PHP Upgrades

We asked Ryan, our web developer, to explain why PHP upgrades are important for websites. As your bonus, I will once again attempt to translate his answers into common English so we can all understand what is meant. Refer to VIA Idea #44 to see my last translation.

VIA Idea #51: Stay Current with PHP Upgrades

  1. Michelle: Starting with the basics, what is PHP?
    Ryan: PHP is a server-side scripting language designed primarily for web development but also used as a general-purpose programming language. PHP originally stood for Personal Home Page but it now stands for the recursive acronym Hypertext Preprocessor. All that means is PHP code can be inserted into the HTML of a Web page.Did you know that as of January 2017, there are over 935 million websites in play on the World Wide Web, and 82.6 percent use a version of PHP? The most-used and supported version is PHP 5.0; these make up 92.3 percent of websites created with PHP code.
    Translation: Website developers really, really like PHP and use it all the time. A “supported software version” means that if a problem occurs, software developers are actively investigating the issue and sending you update patches with the fixes.
  2. Michelle: I’m wondering what other programming languages are out there.
    Ryan: There are dozens out there, some that are well known, such as HTML, ASP and JavaScript. At the other end of the spectrum, there are languages that are rarely used such as Intercal and Whitespace.
    The thing to remember is that even though websites are built in PHP, it doesn’t mean other languages are not used as well. PHP is a server-side script, meaning it runs functions and scripts on your host server before it renders the front end of the website that your visitors will see. PHP works well with other languages such as HTML, CSS, JavaScript and dozens of others to create very powerful websites and applications.
    My Comments: I’m sorry I asked…not sure it matters to our topic of keeping website PHP code updated.
  3. Michelle: Getting back on track: why are there so many versions of PHP?Ryan: People like me work to help grow technology with field advancements in languages such as PHP to bring forth updates and new versions. The most recent version of PHP is v7. Since it is still so new, only 5.5 percent of PHP servers are running it. PHP v5 is still the most-utilized version. Older versions like 5.2x still exist and are used by some web applications, but we are starting to see problems as we move forward with new servers and recent software updates.I skipped PHP v6 because it collapsed in 2010. It’s important to realize that even though it failed, it spawned the intl extension and other features that are now part of the language in v5.x or 7.
    This Means: Programming is always reaching and changing for the better.
  4. Michelle: What happens if I don’t update my PHP version?
    Ryan: If you run PHP v5.2x or lower, you may not initially see anything wrong with your website, but it’s important to remember that your website needs to be up-to-date. New PHP scripts, codes and function may not run on older versions. For example, most content management systems (CMS) on websites run a WYSIWYG (What You See Is What You Get) editor, similar to WordPress. This feature requires a minimum version of 5.3 to even run. So as you add new features to your website or CMS, it is imperative that you ensure your server-side software is up-to-date.
    Example: A client of ours recently asked us to add a new CMS feature to the editing part of their website. They wanted a lightweight, stand-alone editor that would allow them to change their website’s text and images. Once installed, we realized the new feature (in this case KCFinder) would not let them employ “image upload” or “file upload”. Only after we tried to upload a file, did we get the warning that the KCFinder required PHP v5.3 or higher. So our client contacted their website host and requested that they update their legacy server. The host informed them that they would be happy to update them to PHP v5.5, from v5.23. Afterwards the client was able to upload images, but a new issue popped up. PHP error codes appeared about “deprecated code” throughout the entire website. We found that the client’s initial CMS installed on the website worked with PHP v5.4 but was never updated for v5.5. PHP v5.5 deprecates the standard mySQL database calls and encourages you to use mySQLI or PDO. We updated all the CMS mySQL calls to the new standard and removed all the errors. Some PHP scripts for special functionality do not work on every PHP version. One seemingly small update started an unforeseen chain of events. Even though it may have been frustrating, it was a good thing to move away from the old server and code.
  5. Michelle: Thank you for that real-life example. Does PHP automatically update itself? How do I know what version my website is running?
    Ryan: PHP needs to be manually updated, and this is best done by a developer to make sure it is a smooth transition.
    Translation: Chances are if your website hasn’t been touched in three years or more, your code hasn’t been touched either. The next time you want to add a new feature or make a change, you may run into a conflict between the server and the code on your website.

If your website is out of date, needs PHP upgrades or suffers from one of the flaws mentioned previously, the VIA Marketing team will be happy to help. Contact Julie and we will recommend PHP updates to keep you on the cutting edge – or at least running without error messages.

Leave a Reply

Your email address will not be published. Required fields are marked *