Verfasst: 25.09.2003 21:26
mist :-/ bbcode.php/tpl sehen absolut ok aus nur das posting.php teil (in der nähe des quiz hack) wirkt irgendwie änders :-S bad 

phpBB.de - Die deutsche phpBB-Community
https://www.phpbb.de/community/
Code: Alles auswählen
else
{
if ( $mode == 'quote' )
{
$topic_id = $post_info['topic_id'];
}
// BEGIN Quiz Hack
$auth_answer = false;
if ( $mode == 'reply' && $userdata['session_logged_in'] && $post_info['topic_quiz'] == 1 )
{
include($phpbb_root_path . 'includes/quiz.'.$phpEx);
if ( $quiz->check_answer_auth($topic_id, $userdata) )
{
$auth_answer = true;
$post_data['quiz_answer'] = !empty($answer) ? $answer : '';
}
}
// END Quiz Hack
$post_data['first_post'] = ( $mode == 'newtopic' ) ? true : 0;
$post_data['last_post'] = false;
$post_data['has_poll'] = false;
$post_data['edit_poll'] = false;
}
}
else
{
message_die(GENERAL_MESSAGE, $lang['No_such_post']);
}
//
// The user is not authed, if they're not logged in then redirect
// them, else show them an error message
//
//-- mod : calendar
// || (!empty($is_auth_type_cal) && !$is_auth[$is_auth_type_cal])
//-- modify
if ( !$is_auth[$is_auth_type] || (!empty($is_auth_type_cal) && !$is_auth[$is_auth_type_cal]))
//-- fin mod : calendar
{
if ( $userdata['session_logged_in'] )
{
if (!empty($is_auth_type_cal) && !$is_auth[$is_auth_type_cal])
{
message_die(GENERAL_MESSAGE, sprintf($lang['Sorry_' . $is_auth_type_cal], $is_auth[$is_auth_type_cal . "_type"]));
}
//-- fin mod : calendar
message_die(GENERAL_MESSAGE, sprintf($lang['Sorry_' . $is_auth_type], $is_auth[$is_auth_type . "_type"]));
}
switch( $mode )
{
case 'newtopic':
$redirect = "mode=newtopic&" . POST_FORUM_URL . "=" . $forum_id;
break;
case 'reply':
case 'topicreview':
$redirect = "mode=reply&" . POST_TOPIC_URL . "=" . $topic_id;
break;
case 'quote':
case 'editpost':
$redirect = "mode=quote&" . POST_POST_URL ."=" . $post_id;
break;
}
$redirect .= ($post_reportid) ? '&post_reportid=$post_reportid' : '';
redirect(append_sid("login.$phpEx?redirect=posting.$phpEx&" . $redirect, true));
}
//
// Set toggles for various options
//
if ( !$board_config['allow_html'] )
{
Code: Alles auswählen
else
{
if ( $mode == 'quote' )
{
$topic_id = $post_info['topic_id'];
}
// BEGIN Quiz Hack
$auth_answer = false;
if ( $mode == 'reply' && $userdata['session_logged_in'] && $post_info['topic_quiz'] == 1 )
{
include($phpbb_root_path . 'includes/quiz.'.$phpEx);
if ( $quiz->check_answer_auth($topic_id, $userdata) )
{
$auth_answer = true;
$post_data['quiz_answer'] = !empty($answer) ? $answer : '';
}
}
// END Quiz Hack
$post_data['first_post'] = ( $mode == 'newtopic' ) ? true : 0;
$post_data['last_post'] = false;
$post_data['has_poll'] = false;
$post_data['edit_poll'] = false;
}
}
else
{
message_die(GENERAL_MESSAGE, $lang['No_such_post']);
}
//
// The user is not authed, if they're not logged in then redirect
// them, else show them an error message
//
if ( !$is_auth[$is_auth_type] || (!empty($is_auth_type_cal) && !$is_auth[$is_auth_type_cal]) )
//-- fin mod : calendar ----------------------------------------------------------------------------
{
if ( $userdata['session_logged_in'] )
{
//-- mod : calendar --------------------------------------------------------------------------------
//-- add
if (!empty($is_auth_type_cal) && !$is_auth[$is_auth_type_cal])
{
message_die(GENERAL_MESSAGE, sprintf($lang['Sorry_' . $is_auth_type_cal], $is_auth[$is_auth_type_cal . "_type"]));
}
//-- fin mod : calendar ----------------------------------------------------------------------------
message_die(GENERAL_MESSAGE, sprintf($lang['Sorry_' . $is_auth_type], $is_auth[$is_auth_type . "_type"]));
}
switch( $mode )
{
case 'newtopic':
$redirect = "mode=newtopic&" . POST_FORUM_URL . "=" . $forum_id;
break;
case 'reply':
case 'topicreview':
$redirect = "mode=reply&" . POST_TOPIC_URL . "=" . $topic_id;
break;
case 'quote':
case 'editpost':
$redirect = "mode=quote&" . POST_POST_URL ."=" . $post_id;
break;
}
$redirect .= ($post_reportid) ? '&post_reportid=$post_reportid' : '';
redirect(append_sid("login.$phpEx?redirect=posting.$phpEx&" . $redirect, true));
}
//
// Set toggles for various options
//
if ( !$board_config['allow_html'] )
{
Code: Alles auswählen
// BEGIN Quiz Hack
$sql = "SELECT config_name, config_value FROM " . QUIZ_CONFIG_TABLE . " WHERE config_name IN ('next_quiz','last_start_time','disable','next_quiz_step','next_quiz_step_mode')";
if ( !($quiz_result = $db->sql_query($sql)) )
{
if ( defined('Install_Quiz') )
{
$quiz_config['disable'] = true;
}
else
{
message_die(GENERAL_ERROR, "Could not get quiz config information", "", __LINE__, __FILE__, $sql);
}
}
while ( $quiz_row = $db->sql_fetchrow($quiz_result) )
{
$quiz_config[$quiz_row['config_name']] = $quiz_row['config_value'];
}
// Variate quiz time +/- 10%
mt_srand( (double) microtime() * 1000000 );
$next_step_secs = $quiz_config['next_quiz_step'] * 3600;
switch($quiz_config['next_quiz_step_mode'])
{
case 0:
break;
case 1:
$next_step_secs *= 24;
break;
case 2:
$next_step_secs *= (24 * 7);
break;
case 3:
$next_step_secs *= (24 * 7 * 4);
break;
case 4:
$next_step_secs *= (24 * 7 * 4 * 52);
break;
}
$random_seconds = mt_rand(0, ($next_step_secs / 5)) - ($next_step_secs / 10);
$current_time = time() + $random_seconds;
Parse error: parse error, unexpected T_ELSE in /is/htdocs/52270/www.Forum.de/phpBB2_plus_1.2/phpBB2/inc ... search.php on line 516
Warning: Cannot modify header information - headers already sent by (output started at /is/htdocs/52270/www.Forum.de/phpBB2_plus_1.2/phpBB2/inc ... ch.php:516) in /is/htdocs/52270/www.Forum.de/phpBB2_plus_1.2/phpBB2/posting.php on line 618
Warning: Cannot modify header information - headers already sent by (output started at /is/htdocs/52270/www.Forum.de/phpBB2_plus_1.2/phpBB2/inc ... ch.php:516) in /is/htdocs/52270/www.Forum.de/phpBB2_plus_1.2/phpBB2/inc ... header.php on line 647
Warning: Cannot modify header information - headers already sent by (output started at /is/htdocs/52270/www.Forum.de/phpBB2_plus_1.2/phpBB2/inc ... ch.php:516) in /is/htdocs/52270/www.Forum.de/phpBB2_plus_1.2/phpBB2/inc ... header.php on line 649
Warning: Cannot modify header information - headers already sent by (output started at /is/htdocs/52270/www.Forum.de/phpBB2_plus_1.2/phpBB2/inc ... ch.php:516) in /is/htdocs/52270/www.Forum.de/phpBB2_plus_1.2/phpBB2/inc ... header.php on line 650