Jump to content

PHP errors causing "Internal Server Error"


interpim

Recommended Posts

Hi all... I have a question, every once in a while I get an internal server error on my website, and to be quite honest I am a complete PHP newbie. I read that sometimes PHP errors can cause this, so I looked into my scripts.log file and found a re-occuring error there. Can someone help me decipher it and help me out with what I need to change?

here is the error...
[14-Apr-2006 02:40:55] PHP Warning: setlocale(): Passing locale category name as string is deprecated. Use the LC_* -constants instead. in /fenrisguild/mainfile.php on line 565

and here is the code for that area of the php file.
Website is [a href=\"http://fenrisguild.com\" target=\"_blank\"]http://fenrisguild.com[/a] and I am using phpnuke for it. Actual physical location of the site is [a href=\"http://fenrisguild.interpim.com\" target=\"_blank\"]http://fenrisguild.interpim.com[/a] if the forwarded address doesn't work.


[code]
559 /*********************************************************/
560 /* formatting stories                                    */
561 /*********************************************************/
562
563 function formatTimestamp($time) {
564     global $datetime, $locale;
565     setlocale ("LC_TIME", "$locale");
566     ereg ("([0-9]{4})-([0-9]{1,2})-([0-9]{1,2}) ([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2})", $time, $datetime);
567     $datetime = strftime(""._DATESTRING."", mktime($datetime[4],$datetime[5],$datetime[6],$datetime[2],$datetime[3],$datetime[1]));
568     $datetime = ucfirst($datetime);
569     return($datetime);
570 }
[/code]

Thanks to anyone that can help :)
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.