Yahoo Answers is shutting down on May 4th, 2021 (Eastern Time) and the Yahoo Answers website is now in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.
Trending News
Does PHP version matter?
Hello,
I am working on a personal webpage with very basic knowledge of html, so I apologize for the simplicity of the question.
I have a php file that was tested and ran fine with Apache in XAMPP. When I run phpinfo on the apache server, the current version is 5.6.28. Given that my code runs on Apache, I'm guessing my php code is for version 5.6.
Unfortunately, my web hosting server only offers php 5.2, 5.3, 5.5, and 7. The web hosting server is currently set to php 5.5, and I'm guessing this is why my php code doesn't work on the live server.
Since php7 seems to be the most current version, I figured I should run the web server with php7, but I'm guessing my code won't necessarily be compatible. Is this correct? Would I need to update my current code to version 7? Is there a tool I can use that would automatically convert my code as I'm not comfortable enough with coding to do it myself. It's a rather simple code, so I'm guessing some sort of tool should be suffice for my needs, but I can't seem to find any.
This is my current code:
Any help would be greatly appreciated.
Thank you.
1 Answer
- 4 years ago
Simply google all the functions used in your php files and change them for the version of your web host & it's problem solved :) 5.5 isn't much different to 5.6 so I doubt that is why your code isn't working.