Welcome to the dBforums forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions, articles and access our other FREE features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload your own photos and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact support.

If you prefer not to see double-underlined words and corresponding ads, place your cursor
here for ContentLink opt out.

Go Back  dBforums > Data Access, Manipulation & Batch Languages > PHP > STRICT error with "getdate()" function

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 10-07-07, 07:25
ABo YaSSeR 4 EvER ABo YaSSeR 4 EvER is offline
Registered User
 
Join Date: Oct 2007
Posts: 3
STRICT error with "getdate()" function

Hi,

Why this STRICT error came into view?

Strict Standards: getdate() [function.getdate]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Moscow' for '3.0/no DST' instead in C:\xampp\htdocs\aboyaser\core.php on line 126

??

I need full description about this message.


Thankx a lot
Reply With Quote
  #2 (permalink)  
Old 10-08-07, 09:53
aschk aschk is offline
Registered User
 
Join Date: Mar 2007
Location: 636f6d7075746572
Posts: 734
Basically PHP doesn't know which timezone you're in. Thus it is telling you that your system time is unreliable without this modifier.

By the looks of the error message you most likely did something like the following :
Code:
date_default_timezone_set('3.0/no DST')
which is NOT a timezone.

Without the actually line of code I can't tell you. However I would suggest you do what has been advised in the error message and alter (or add) the line like the following :
Code:
date_default_timezone_set('Europe/Moscow');
Reply With Quote
  #3 (permalink)  
Old 10-08-07, 09:54
aschk aschk is offline
Registered User
 
Join Date: Mar 2007
Location: 636f6d7075746572
Posts: 734
Alternatively of course you could look up the error message or the functions on php.net ... but maybe you're too lazy to do that
Reply With Quote
  #4 (permalink)  
Old 10-08-07, 22:04
ABo YaSSeR 4 EvER ABo YaSSeR 4 EvER is offline
Registered User
 
Join Date: Oct 2007
Posts: 3
Thanks a lot

The code is like this:

Code:
$get_date = getdate(1234567890);
Reply With Quote
  #5 (permalink)  
Old 10-11-07, 09:01
aschk aschk is offline
Registered User
 
Join Date: Mar 2007
Location: 636f6d7075746572
Posts: 734
That's fine, but you still need to set the timezone because it is required. See my previous post and follow the steps there to set the right timezone.
Reply With Quote
  #6 (permalink)  
Old 10-12-07, 04:28
ABo YaSSeR 4 EvER ABo YaSSeR 4 EvER is offline
Registered User
 
Join Date: Oct 2007
Posts: 3
Thanks a lot
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On