Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Security - PHP Nuke
Author Message
heavymo
New Member
New Member



Joined: Jul 07, 2004
Posts: 8

PostPosted: Wed Jul 07, 2004 4:11 am Reply with quote

hi all , well basically i have the time set properly on the phpbb to GMT +1 which say comes out to be 4:00 for example, the scrolling forum block gets the right posts and date but adds an hour to the time so it is infact GMT +2 so e.g 5:00 how can i sort this out because it has added some confusion with members.


thank you.
 
View user's profile Send private message
Raven
Site Admin/Owner



Joined: Aug 27, 2002
Posts: 17088

PostPosted: Wed Jul 07, 2004 4:34 am Reply with quote

This is not a block issue, unfortunately. The block does not add any time, it just does not adjust it as phpbb does. This is a phpnuke issue. Nuke does not allow for adjusting the server time which is what you are seeing. I would imagine you have the same issue with the time in your News stories unless you have modified code for that.
 
View user's profile Send private message
heavymo







PostPosted: Wed Jul 07, 2004 4:55 am Reply with quote

yep same problem so ive decided to remove the time from news and stories... so there is no way around this then?
 
Raven







PostPosted: Wed Jul 07, 2004 5:02 am Reply with quote

I collected this along the way but it may not be up to date with your version of nuke, but you can try the logic. Notice the -15? That, if I remember right, is the HOUR offset. Let me know if this works or not Smile
Code:
function formatTimestamp($time) {

    global $datetime, $locale;
    setlocale (LC_TIME, $locale);
    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);
    $datetime = strftime(""._DATESTRING."", mktime(($datetime[4]-15),$datetime[5],$datetime[6],$datetime[2],$datetime[3],$datetime[1]));
    $datetime = ucfirst($datetime);
    return($datetime);
}
 
heavymo







PostPosted: Wed Jul 07, 2004 5:08 am Reply with quote

ive configured the time based on that script , so now i have correct story time , but scrolling forum block is unaffected.
is it possible to call the time From_ bb time at all?
thanks.
 
Raven







PostPosted: Wed Jul 07, 2004 5:42 am Reply with quote

Probably but I don't have any code to do that. Rather, I would just make a call to the function above and pass it the posting time from the block. It should come back adjusted correctly.
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Security - PHP Nuke

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©