I want to upgrade my PHP version from 5.2.3 to 5.5.9. I want to know what are the major problems involved with the functionality after upgradation .
My PHP is running in WAMP server.
Thanks in advance
The short answer is that yes, your code could break so you should test it.
Here's the list of Backward Incompatible Changes from PHP 5.2 to 5.3
And here's the list of Backward Incompatible Changes from PHP 5.3 to 5.4
And here's the list of Backward Incompatible Changes from PHP 5.4 to 5.5
Read each of these and see if you're using any of those functions in the ways described.
Related
Do you know how to downgrade php from 5.6 to 5.3?
I created a website with PHP 5.6 but when my client uploaded on their server some functions on my website are not compatible and they say that the problem is because their PHP version is 5.3 and I don't know about it, so they want me to downgrade my PHP version. Can you help me?
Or any solution to my problem? So, my website can be compatible on their server.
You're most likely talking not about downgrading of the PHP executables, but about downgrading language level from 5.6 to 5.3
There is no automatic way to do it, but you can study syntax changes between versions (information can be found into official manual) and update your code accordingly.
Also it may be good idea to remind customer that PHP 5.3 is not supported anymore so it may be good idea to upgrade PHP version instead of downgrading site. 5.3 -> 5.6 upgrade is relatively plainless.
I am changing my project from php version 5.2.1 to 7(new version), but the project is in codegnitor version 1.7.2, So i should change php version,mysql to mysqli . Should i change Codegnitor version also
Should not be needed since php is (mostly) backwards compatible. I would however recommend to do it anyway.
Recently, I require to upgrade PHP version from 5.3.3 to higher. Can any one tell me which version of PHP I should upgrade for? Which one is more stable? PHP 5.4 or 5.5 or 5.6?
The latest stable version is PHP 5.6.11
According to the release history, 5.4 is only getting security updates and 5.5 will stop getting bug fixes in 10 months. So 5.6 is your best bet. Considering there are only minor syntax changes between these versions, you should go for the latest anyway.
The 5.3 to 5.4 gap may require some alterations in your code. And if your code works on 5.4, it will also work on 5.6, so just use the latest.
There is a bug in php 5.3 with the iconv module. Apple applied a patch for their version of php. However, MAMP didn't include this patch and is thus unusable with Zend Framework (for example).
I tried to include Apple's version of php 5.3 into the MAMP's httpd.conf, but ran into problems with symbols which could not be found. Does anyone know of a proper way to use MAMP with php 5.3 /w iconv? Is recompiling or linking apple's version an option?
Just rename the php directories in /Applications/MAMP/bin/php
Duplicate php 5.3 directory and rename it to the same ver number of 5.2, and it works. :d
I'm not sure this leave a whole lot of value in the MAMP, but you probably are best served compiling your own php and apache.
http://fabien.potencier.org/article/37/php-5-3-0-on-mac-os-10-6-snow-leopard
There is a discussion of this issue here:
iconv_strlen function causing execution timeout, running on MAMP
The basic solution is either to downgrade your MAMP to version 1.9.4 which is the last stable version as far as “iconv” is concerned. Or you can use any version of MAMP from 1.9.5 onwards but switch the PHP version from the MAMP preferences from 5.3 to 5.2.
What are the differences between PHP 5.2.x and 5.3.x?
Because all extensions are made separately for these.
Thanks a lot.
PHP 5.3 is a newer version with a number of new features (closures, namespaces, etc.). Is is the current stable version for the PHP project. PHP 5.2 is an older version, which is now heading towards the end of its support cycle - now only important security issues are being fixed. If you start a new project, start it with PHP 5.3.
When changes in PHP core are made that change the structure enough that extensions can no longer be compatible - the second digit in the version number is incremented (5.0, 5.1, 5.2, 5.3). The first digit is for very major changes changing the whole language (like between PHP 4 and 5). Between 5.2 and 5.3, you can expect source code compatibility (though some incompatibilities exist) but not binary module compatibility.
You can find an exhaustive list of backwards incompatible changes from 5.2 to 5.3 on PHP.net.
PHP extensions depends on the phpapi version among other things, along with the Zend Module API version and the Zend Extension API version, which as far as I'm aware, changes at each PHP version because of the core changes made to the language. This explains why each PHP version has a new build for each extension.
You can find the answer in PHP official website.
In this page: Migrating from PHP 5.2.x to PHP 5.3.x.