PHP 1... because that's old-school![]()
| SitePoint Sponsor |
PHP 4
PHP 5


PHP 1... because that's old-school![]()
Choose Life. Choose a job. Choose a career. Choose a family.
Choose washing machines, cars, tableless sites, and SEO.
Choose DIY and wondering who the f' you are on a Sunday morning.
Choose a marketing strategy. Choose your future. Choose life.


PHP 4 isn't more stable nor more reliable compared to 5. Stop showing your incompetence.Originally Posted by GzThai
Use PHP4, it's faster.


I want to use PHP 5, but my current hosting provider is stuck on PHP 4, and to make matters worse, he's using the iBizWeb control panel. Talk about YUCK!
Save the Internet - Use Opera | May my mother rest in peace: 1943-2009
Dan Schulz - Design Team Advisor | Follow me on Twitter
SitePoint References: HTML CSS JavaScript | Become A Guru
WordPress SEO Checklist | What WordPress Plugins Do You Use?
Web Standards Curriculum | Image Free Equal Height Columns




No, it's not. Don't confuse proceedural vs. object-oriented raw code execution time with php4 vs. php5. Every succeeding php version has made speed improvements and tweaks, and php5 is no exception. PHP5 is much faster with OO code than PHP4 is. As previously stated by another member, don't show your incompetence with statements like this and no facts to back them up.Originally Posted by wiskers
Stackbox CMS - Full edit-on-page drag-and-drop CMS
Autoridge - Vehicle information & maintenance part numbers
Twitter | Blog | Online Javascript Compressor

I use PHP4 simply because it's widely supported. If I'm doing work for people, I know that PHP4 will definitely work--whereas it's 50/50 with PHP5.
PHP 5 is preferred, but a lot of my hosting providers still have 4, actually most of them do. They will only change if the market demands it. Right now that is not happening as most people are comfortable and just as satisfied with PHP 4.

php4 for most projects. php 5.1 has some bugs they have to sort outmainly the "using apache mod_rewrite will occasionaly give you a white page" bug
Kilian Valkhof | KilianValkhof.com - Soon... | I love my job!

My hosting has both installed and just uses different extensions to identify which to use
.php = PHP4
.php5 = PHP5
I think this is the simplest solution as it allows for scripts to be upgraded on a page by page basis.
Stephen J Chapman
javascriptexample.net, Book Reviews, follow me on Twitter
HTML Help, CSS Help, JavaScript Help, PHP/mySQL Help, blog
<input name="html5" type="text" required pattern="^$">
i dont know why People say PHP 4 , PHP 5 is way much better than php4 thousands of new features and better performance on my local server PHP 5 is installed i mostly developer apps on PHP 5 and they can be eaisly deployed with PHP 4. i think most ppl use php 4 cuz its come default with most of the COntrol Panels Like Cpanel


Currently using PHP 4 but building a new server to switch to PHP 5. There are many new features in PHP 5 I would love to take advantage of and everyone will be switching sooner or later. I am also using Apache 2 and Mysql 5 with the new system and everything works great, using OOP and extensive mod_rewrite on majortiy of sites.
There is no looking back.


You can develop for both at the same time. A little extra work prehaps, but maybe it would be worth it?
"Never imagine yourself not to be otherwise than what
it might appear to others that what you were or might
have been was not otherwise than what you had been
would have appeared to them to be otherwise."

php5: because I just got a job developing php5 applications.
I fell in love with PHP 5. It's so much better when programming OO.
I use version 4 at my regular job, but when creating sites myself, I only use php5. There are enough great hosts that support php5. If you can choose the host for your client, I would definitely take a php5 host.
I hope adoption will be much faster when php6 arrives.
I would stick with php 5. There is a reason why they have updated the version, to provide more and better results from php. Let's just hope that when php 6 comes out these problems are not faced again.

I had a number of problems when PHP 5 changed on my server. I used my custom programmed PHP-SQL session handling written in PHP4. I've moved it to my host and: Welcome boy ! - all stuck. I've searched net for a few days until I found a valuable solution for my situation. Although it was not the best solution I expected, but it worked. A few days after my hosting provider moved back to PHP 4 (I suppose there was a number of similar problem with other clients) and i had to change all back... that was a funny part
Conclusion: I'm sure and I know PHP 5 has a number of nice features over PHP 4, but backward capability is the main trouble so if you have your code in PHP 4 be ready to some unexpected surprises, especally in class related section.


PHP 4 and 5 are at the same cross-roads that Web design itself was at a few years ago. At that point in time we were all designing with tables, frames and using scripts for browser detection.
Then came along a newer, better way of creating our sites. Semantic (X)HTML markup for structure, CSS for presentation, and a standardized DOM that degraded nicely in older browsers by checking for object support rather than sniffing for browsers. It was a painful transition, but one that I doubt anyone will argue was better for the industry over the long term.
We're seeing the same "growing pains" with PHP right now.
Save the Internet - Use Opera | May my mother rest in peace: 1943-2009
Dan Schulz - Design Team Advisor | Follow me on Twitter
SitePoint References: HTML CSS JavaScript | Become A Guru
WordPress SEO Checklist | What WordPress Plugins Do You Use?
Web Standards Curriculum | Image Free Equal Height Columns
Yes, you can envision the resemblance but there was one big difference. All that was client side issues. The host providers were not involved. In this case they are, and that's exactly what's holding us back.Originally Posted by Dan Schulz
After all thoughts and opinions expressed in this thread, this is the conclusion that I've come to:
The time has not come yet to drop PHP 4 support in commercial products. We cannot differentiate our clients by their abilities to choose a host provider or force them to switch to PHP 5, for they are too valuable. Let's leave this to non-commercial open source products, only they can push PHP 5 to come.
Saul


The difference in this case is a different type of vendor. Back then the vendors were the browser manufacturers. Now we're dealing with hosting providers.
As I said, PHP is in a state of transition right now. Just as eldacar said, the best route to go right now would be to code applications that work in both PHP 4 and 5, so that regardless of the version installed, it can be expected to work (more or less) the same.
Save the Internet - Use Opera | May my mother rest in peace: 1943-2009
Dan Schulz - Design Team Advisor | Follow me on Twitter
SitePoint References: HTML CSS JavaScript | Become A Guru
WordPress SEO Checklist | What WordPress Plugins Do You Use?
Web Standards Curriculum | Image Free Equal Height Columns

Most PHP4 scripts (as far as I can tell) are not going to work on a PHP5 server, which is why most web hosts don't support it or include both 4 and 5.
If your host has PHP4 and PHP5 you could use .htaccess to tell Apache to parse .php file names with PHP5. A lot of hosts now are at least installing 4 and 5 on their servers...
Yes, there were browser manufacturers but still there was no such backward incompatibility, which is the main reason of this behaviour of hosting providers. Anyway there really is a resemblance.
Again, yes, we could push it by dropping PHP 4, but can we pay this price on our businesses' account? I think not. However if we push it with open source projects, we loose nothing.
Saul

Hmm, but you can always install both.Originally Posted by Carl
Well I wish there was an option for bothWe run both PHP4 and PHP5 on our servers, and it's not a "one or the other" situation either.
I find it works out nice for me personally because I do development work, so I like to be able to specify PHP4 for some folders, or PHP5 for others.
I definately enjoy working with PHP5 though, been itching to play with it!
█ Crucial Web Hosting
█ Our new site is live! Introducing Split-Shared and Split-Dedicated hosting products!
█ Join our new Developer Network and check out the updated Site Showcase!
If possible with your host, I'd say go with php5, they upgraded it for a reason!





Yeah, I agree with the above. Go with PHP5. It seems that most hosting companies must be scanning through sitepoint forums and are actually offering PHP5 more readily.
intragenesis, llc professional web & graphic design
Bookmarks