Not Solved [Help] Ajax Chat Date & Time wrong
#1
Not Solved
Hey guys, i installed
http://mods.mybb.com/view/ajax-chat
in our forum.

The problem now is the date and the time.

In this plugin it will show us

1.7.14 8:29

but in my country it is:

7.1.14 14:29.

This means the time is 6 hours back than mine and the date is MMBig GrinD but i need DD:MM.

Where can i change these things? I havenĀ“t find it under templates and haven t find it in the .php maybe somebody could help me.

greetz
Reply
#2
Not Solved
open ./chat_frame.php file in a code editor (eg. notepad++) - around line 23 find code line like below
$date = date('n/j/y G:i', $row["date"]);

you can change it to
$date = date('j/n/y G:i', $row["date"]);
see more details about php date format if required
Reply
#3
Not Solved
Ty this works, but i also have the problem that the time is 6 hours back of my country
Reply
#4
Not Solved
^ can we know your time zone - what is the difference between your local time and UTC (GMT)
Reply
#5
Not Solved
My time is GMT +1 (20:04 atm)
on the chatbox its at the moment 14:04
Reply
#6
Not Solved
^ can you add below code line to chat_frame.php file after line 20 as a new line and check time by refreshing the chat box
date_default_timezone_set('Europe/Amsterdam'); 
add it after $parser = new postParser(); - it looks like below
$parser = new postParser();
date_default_timezone_set('Europe/Amsterdam');
while($row = $db->fetch_array($result))
Reply
#7
Not Solved
works ty!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)