I notice you've got seperate versions for php 4 and 5. I'm wondering if it is possible to have the same version run on both, perhaps at the price of sacrificing some functionality (all the new fancy stuff with php 5)?
I'm trying to test out php 5 (more specifically 5.2) and to see if I can get my project to work on both. My project depends on your's and several others.
I'd like to avoid having to offer seperate versions of my software for 4 and 5, because I don't think I need the new functionality from 5.
Does your php 4 version work fine on php 5?
PHP 4 vs PHP 5
Moderators: Chris Corbyn, General Moderators
- Maugrim_The_Reaper
- DevNet Master
- Posts: 2704
- Joined: Tue Nov 02, 2004 5:43 am
- Location: Ireland
- Chris Corbyn
- Breakbeat Nuttzer
- Posts: 13098
- Joined: Wed Mar 24, 2004 7:57 am
- Location: Melbourne, Australia
There's no way I'll ever drop the PHP5 branch. It's little effort to me to develop under PHP5 and then quickly "translate" that the PHP4 before releasing. PHP5 will run PHP4 code and it should run the PHP4 branch of swift just fine. But it will not run well under E_STRICT. Not long after PHP6 is released I need to consider whether to deprecate the PHP4 version or maintain 3 version because (if they ever implement it!) I'd like to take full advantage of namespacing to clean things up a little.
Just use the PHP4 version, but don't expect it run work without warning or notices on all servers
Just use the PHP4 version, but don't expect it run work without warning or notices on all servers
- AKA Panama Jack
- Forum Regular
- Posts: 878
- Joined: Mon Nov 14, 2005 4:21 pm
Actually, you CAN write PHP 4 code and classes that will not show any errors under E_STRICT settings when running under PHP 5. Personally I am not going to create PHP 5 only versions of my projects because it really isn't needed for the most part.
The E_STRICT error from the use of VAR in classes was removed in PHP Version 5.1.3 back in May. So you can create 100% PHP 4 code that doesn't throw any E_STRICT errors in PHP. This way you can have one branch that works on PHP 4 and PHP 5 without E_STRICT errors. I was glad they finally fixed the VAR oversight.
The E_STRICT error from the use of VAR in classes was removed in PHP Version 5.1.3 back in May. So you can create 100% PHP 4 code that doesn't throw any E_STRICT errors in PHP. This way you can have one branch that works on PHP 4 and PHP 5 without E_STRICT errors. I was glad they finally fixed the VAR oversight.
- Chris Corbyn
- Breakbeat Nuttzer
- Posts: 13098
- Joined: Wed Mar 24, 2004 7:57 am
- Location: Melbourne, Australia
I use interfaces, abstract classes, exceptions, static class members. Interfaces and abstract classes come in extremely useful when you're writing a pluggable system. I know I can get by without them but those features exist in OOP for a reasonAKA Panama Jack wrote:Actually, you CAN write PHP 4 code and classes that will not show any errors under E_STRICT settings when running under PHP 5. Personally I am not going to create PHP 5 only versions of my projects because it really isn't needed for the most part.
The E_STRICT error from the use of VAR in classes was removed in PHP Version 5.1.3 back in May. So you can create 100% PHP 4 code that doesn't throw any E_STRICT errors in PHP. This way you can have one branch that works on PHP 4 and PHP 5 without E_STRICT errors. I was glad they finally fixed the VAR oversight.