homepage Welcome to WebmasterWorld Guest from 23.22.194.120
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Visit PubCon.com
Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
Forum Library, Charter, Moderators: coopster & jatar k

PHP Server Side Scripting Forum

    
error in timezone. What happened?
zozzen




msg:4151901
 8:04 am on Jun 13, 2010 (gmt 0)

Hi,

I'm using mediawiki to build a website and in many case, when the php uses date( ) function, it appears the error "It's not safe to rely on the System's Timezone settings....." .

I understand that this is a quite common question, and i've spent many time to search for solutions. I tried it but it just doesn't work for me...


In c:\xampp\php\php.ini , i set my timezone there. (my computer clocks is in Asia time now, but i set it to Euro
[Date]
; Defines the default timezone used by the date functions
; [php.net...]
date.timezone = "Europe/London"
;
; [php.net...]
;date.default_latitude = 31.7667

; [php.net...]
;date.default_longitude = 35.2333

; [php.net...]
;date.sunrise_zenith = 90.583333

; [php.net...]
;date.sunset_zenith = 90.583333


And in mediawiki's setting file - localsetting.php, i've also added:
#Set Default Timezone
$wgLocaltimezone = "Europe/London";


Do you know why it happens to me...?

 

Little_G




msg:4151933
 1:36 pm on Jun 13, 2010 (gmt 0)

Hi,

Did you restart Apache after making the changes to your php.ini?

If you did and it still didn't work then maybe PHP is using another php.ini file, try creating a script that runs phpinfo [php.net] and look through the first table for where it tells you the php.ini path.

Andrew

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / PHP Server Side Scripting
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved