Page 1 of 1

Sites showing year 0000

Posted: Fri Oct 02, 2009 3:03 pm
by AlisonMooreSmith
Hello. I am new hear and first want to apologize if this is the incorrect topic to post in. I couldn't tell what are best fits my question. My sysop (and husband) is currently on a ship running submarine opps and, so, isn't accessible and I'm at a loss.

We have some blogs that have been running on our servers for some time. A few days ago, the power supply on the server fried and I had to grab a free laptop to hook the server hard drive up to. About the same time (although I'm not positive it's related) the years on all the blog entries reset to 0000. Of course, this wreaks havoc with posting, etc., because blog posts (and comments) ordering is all date-based.

I have no idea what happened and could use help to track this down.

Currently the php version is 2.5.10. I know there's an fix for that in 2.5.11 and also a newer version, 2.3. Since I don't know how to upgrade the PHP, I'd like to get feedback on whether or not that will correct the problem before I try to do that.

I did find this bug report:

http://bugs.php.net/bug.php?id=48276

but it indicates that is on version 2.3.

A couple of the blogs in question are here, fyi:

http://www.seerstonehomes.com
http://www.mormonmomma.com

Any help appreciated! I'm dead in the water until I get this figured out.

Re: Sites showing year 0000

Posted: Fri Oct 02, 2009 3:26 pm
by requinix
You're running PHP 5.2.10 (which is the second-to-latest version of the 5.2 tree).

The problem is with the server, not with PHP. Not quite sure what, but start checking the clocks on the computer: both physical (like look what the BIOS says the date is) and software (the operating system).

Re: Sites showing year 0000

Posted: Fri Oct 02, 2009 4:36 pm
by AlisonMooreSmith
Thanks for your help.

Yea, sorry, inverted the version number. 5.2.10

The server is on Mac OSX. Everything LOOKS right on the server. But I reset the parameter ram and also reset the system management controller. Didn't resolve the issue. :banghead:

Any other ideas?

I just found this:

http://discussions.apple.com/thread.jsp ... 4&tstart=0

This says "PHP 5.2.10 has a KNOWN bug on PPC (and other architectures) wherein a call to the date() function returns "0000" for the year."

The computer we are now using for the server is a PowerPC G4. The server we were running before is a G5. We just did the 2009-005 security update, which upgraded PHP to 5.2.10, that's when the problem occurred I think.

Re: Sites showing year 0000

Posted: Fri Oct 02, 2009 6:09 pm
by requinix
AlisonMooreSmith wrote:I just found this:

http://discussions.apple.com/thread.jsp ... 4&tstart=0

This says "PHP 5.2.10 has a KNOWN bug on PPC (and other architectures) wherein a call to the date() function returns "0000" for the year."

The computer we are now using for the server is a PowerPC G4. The server we were running before is a G5. We just did the 2009-005 security update, which upgraded PHP to 5.2.10, that's when the problem occurred I think.
Yeah... I didn't think it was PHP because I was seeing Last-Modified headers in the year 0000 (which are normally sent by the server) but upon further inspection I see that's only on PHP pages - for images and CSS and such it's the right year.

Sounds like you got it right with that bug.

Re: Sites showing year 0000

Posted: Sun Oct 04, 2009 7:08 pm
by AlisonMooreSmith
So...can anyone point me to directions on how to upgrade PHP on an OSX SERVER? I can find directions for a regular Mac (non-server) and for older versions of PHP and Apache. Anyone know anything up-to-date?

Thanks.