Easy Events Mod Uhrzeit Problem

Du hast Probleme beim Einbau oder bei der Benutzung eines Mods? In diesem Forum bist du richtig.
Forumsregeln
phpBB 2.0 hat das Ende seiner Lebenszeit überschritten
phpBB 2.0 wird nicht mehr aktiv unterstützt. Insbesondere werden - auch bei Sicherheitslücken - keine Patches mehr bereitgestellt. Der Einsatz von phpBB 2.0 erfolgt daher auf eigene Gefahr. Wir empfehlen einen Umstieg auf phpBB 3.0, welches aktiv weiterentwickelt wird und für welches regelmäßig Updates zur Verfügung gestellt werden.
Antworten
MT0672
Mitglied
Beiträge: 124
Registriert: 22.07.2006 12:57

Easy Events Mod Uhrzeit Problem

Beitrag von MT0672 »

Tach auch,

habe mir oben genannten Mod eingebaut. Habe das Problem das das Erstellungsdatum des Events mit 01.01.1970 angezeigt wird. Ich bekomms auch nicht raus worans liegt.

Ich vermute mal es liegt an dem putenv('TZ=GMT'); Hat jemand ne Idee ???

Code: Alles auswählen

<?php
define('IN_PHPBB', true);
$phpbb_root_path = './';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);

//
// Start session management
//
$userdata = session_pagestart($user_ip, PAGE_EVENTS);
init_userprefs($userdata);
//
// End session management
//

//announce

//date functions - Change to local timezone

putenv('TZ=GMT');

 	$sql = "SELECT id, title, edate, doors, location, content, flyer, sdate FROM " . EVENTS . " ORDER BY ID DESC LIMIT 3 ";
if ( ! ( $result = $db->sql_query($sql) ) )
{
   message_die(GENERAL_ERROR, 'Error retrieving user data', '', __LINE__, __FILE__, $sql);
}
$events = array();
while( $events[] = $db->sql_fetchrow($result) );
$db->sql_freeresult($result);
$total_events = count($events);



for ($t = 0; $t < $total_events; $t++)
{
	if ($events[$t]['content'] <> ''){

	$template->assign_block_vars('events', array(
	'event_content' => $events[$t]['content'],
	'event_title' => $events[$t]['title'],
	'event_edate' => $events[$t]['edate'],
	'event_location' => $events[$t]['location'],
	//'event_doors' => $events[$t]['doors'],
	'event_flyer' => $events[$t]['flyer'],
	'event_sdate' => date("m.d.y H:i",$announce[$t]['date'])));
}
}


 $template->set_filenames(array(
         'body' => 'events.tpl')
      );

      $page_title = 'Events'; // You'll have to set this in a $lang file somewhere
      include($phpbb_root_path . 'includes/page_header.'.$phpEx);



$template->assign_vars(array(
	)
);
 $template->pparse('body');

 include($phpbb_root_path . 'includes/page_tail.'.$phpEx);

?>
THX
Antworten

Zurück zu „phpBB 2.0: Mod Support“