Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    Regular Coder
    Join Date
    Jan 2006
    Location
    Finland, Hollola
    Posts
    285
    Thanks
    8
    Thanked 0 Times in 0 Posts

    Supporting PHP 4 necessary?

    Hi,

    I'm creating a huge script open for public use. I have written it for PHP 5 (will soon work on PHP 6 too), but I am wondering is it worth to support PHP 4? How many PHP 4 only powered servers are there?
    PHP 5 & MySQL 5 (Y)

  • #2
    Senior Coder djm0219's Avatar
    Join Date
    Aug 2003
    Location
    Wake Forest, North Carolina
    Posts
    1,285
    Thanks
    4
    Thanked 201 Times in 198 Posts
    A good number of hosting providers still don't provide PHP 5 unfortunately. If you restrict it to 5 or higher you're likely going to limit your audience.
    Last edited by djm0219; 08-05-2008 at 07:32 PM. Reason: Typo
    Dave .... HostMonster for all of your hosting needs

  • #3
    Senior Coder
    Join Date
    Sep 2005
    Posts
    1,791
    Thanks
    5
    Thanked 36 Times in 35 Posts
    It isn't necessary, and I personally wouldn't spend any time whatsoever checking or making it work. If it does, then great, but do you really want to be selling to/supporting people who aren't clued up enough to get half-decent hosting? (all the big-names all allow PHP5 now, even if only as an alternative rather than the default - hosts not supporting it is largely a myth, I haven't come across any in the last 6 months or so) and most popular apps are moving towards PHP5 only.

    There hasn't been any new work done on PHP4 since february, and as of this coming Friday it won't even get security fixes. The announcement of the EOL was over a year ago, so any hosting provider who won't support PHP5 is being completely irresponsible.

    At the end of the day though, it's up to you. If you're looking to make money from this, and it becomes obvious there is a market for PHP4 support then consider it. If it's a hobby-type project though, and you just want people to use it, then you're going to cause yourself problems firstly making it work with 4, and secondly supporting people trying to use it.
    My thoughts on some things: http://codemeetsmusic.com
    And my scrapbook of cool things: http://gjones.tumblr.com

  • #4
    God Emperor Fou-Lu's Avatar
    Join Date
    Sep 2002
    Location
    Saskatoon, Saskatchewan
    Posts
    16,979
    Thanks
    4
    Thanked 2,659 Times in 2,628 Posts
    No.
    I support only versions that are current or one version previous. With PHP 6, I wouldn't bother with PHP4. If you really feel you need to, support PHP 4, but don't go back further than 4.2, non-superglobal hell.

    If someone wants to use you're public script but they don't have the correct version of PHP to run it, let them take care of altering the code. Just tell them what version they require to run it - I posted a datacollections with linkedlists, queues and stacks with an indication of 5.1 (or was it 5.2...) minimum to run. If someone doesn't have that version, they just can't use it.
    PHP Code:
    header('HTTP/1.1 420 Enhance Your Calm'); 

  • #5
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    I've had a few clients whose webhosts only had PHP4 installed.
    ||||If you are getting paid to do a job, don't ask for help on it!||||

  • #6
    Regular Coder
    Join Date
    Jan 2006
    Location
    Finland, Hollola
    Posts
    285
    Thanks
    8
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by _Aerospace_Eng_ View Post
    I've had a few clients whose webhosts only had PHP4 installed.
    And how many clients have you had in total?
    PHP 5 & MySQL 5 (Y)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •