diff -r 5e1f1e916419 -r 98bbc533541c punbb/header.php
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/punbb/header.php Sun Apr 06 00:28:50 2008 -0400
@@ -0,0 +1,276 @@
+
+$tpl_main = str_replace('', 'xml:lang="'.$lang_common['lang_identifier'].'" lang="'.$lang_common['lang_identifier'].'" dir="'.$lang_common['lang_direction'].'"', $tpl_main);
+// END SUBST -
+
+
+// START SUBST -
+ob_start();
+
+// Is this a page that we want search index spiders to index?
+if (!defined('PUN_ALLOW_INDEX'))
+ echo ''."\n";
+else
+ echo ''."\n";
+
+// Should we output a MicroID? http://microid.org/
+if (strpos(PUN_PAGE, 'profile') === 0)
+ echo ''."\n";
+
+?>
+
+'."\n";
+ echo ''."\n";
+}
+else if (PUN_PAGE == 'viewforum')
+{
+ echo ''."\n";
+ echo ''."\n";
+}
+
+?>
+
+ 2)
+ echo ''."\n";
+
+// If there are other page navigation links (first, next, prev and last)
+if (!empty($pun_page['nav']))
+ echo implode("\n", $pun_page['nav'])."\n";
+
+?>
+
+
+
+
+
+
+
+
+add_header($tpl_temp);
+ob_end_clean();
+// END SUBST -
+
+
+// START SUBST -
+$tpl_main = str_replace('', 'id="pun-'.PUN_PAGE.'"', $tpl_main);
+// END SUBST -
+
+
+// START SUBST -
+$tpl_main = str_replace('', ''."\n", $tpl_main);
+// END SUBST -
+
+// START SUBST -
+$tpl_main = str_replace('', ''."\n\t".'
'.htmlspecialchars($pun_config['o_board_title']).'
'."\n".'
'."\n", $tpl_main);
+// END SUBST -
+
+
+// START SUBST -
+if ($pun_config['o_board_desc'] != '')
+ $tpl_main = str_replace('', ''."\n\t".'
'.htmlspecialchars($pun_config['o_board_desc']).'
'."\n".'
'."\n", $tpl_main);
+// END SUBST -
+
+
+// START SUBST -
+$tpl_main = str_replace('', ''."\n\t".'
'."\n\t\t".generate_navlinks()."\n\t".'
'."\n".'
'."\n", $tpl_main);
+// END SUBST -
+
+
+// START SUBST -
+$tpl_main = str_replace('', ''."\n\t".'
'.generate_crumbs(false).'
'."\n".'
'."\n", $tpl_main);
+// END SUBST -
+
+
+// START SUBST -
+ob_start();
+
+if ($pun_user['is_guest'])
+{
+ $visit_msg = array(
+ ''.$lang_common['Not logged in'].'',
+ ''.$lang_common['Login nag'].''
+ );
+}
+else
+{
+ $visit_msg = array(
+ ''.sprintf($lang_common['Logged in as'], ''.htmlspecialchars($pun_user['username']).'').'',
+ ''.sprintf($lang_common['Last visit'], ''.format_time($pun_user['last_visit']).'').''
+ );
+
+ $visit_links = array(
+ ''.$lang_common['New posts'].'',
+ ''.$lang_common['Mark all as read'].''
+ );
+
+ if ($pun_user['is_admmod'])
+ {
+ $query = array(
+ 'SELECT' => 'COUNT(r.id)',
+ 'FROM' => 'reports AS r',
+ 'WHERE' => 'r.zapped IS NULL',
+ );
+
+ ($hook = get_hook('hd_qr_get_unread_reports_count')) ? eval($hook) : null;
+ $result_header = $pun_db->query_build($query) or error(__FILE__, __LINE__);
+
+ if ($pun_db->result($result_header))
+ $visit_links[] = ''.$lang_common['New reports'].'';
+ }
+}
+
+($hook = get_hook('hd_visit')) ? eval($hook) : null;
+
+?>
+
+', $tpl_temp, $tpl_main);
+ob_end_clean();
+// END SUBST -
+
+
+// START SUBST -
+$alert_items = array();
+
+if ($pun_config['o_maintenance'] == '1' && $session->user_level >= USER_LEVEL_ADMIN)
+ $alert_items[] = ''.$lang_common['Maintenance mode'].' '.$lang_common['Maintenance alert'].'
';
+
+if ($session->user_level >= USER_LEVEL_ADMIN && $pun_config['o_check_for_updates'] == '1')
+{
+ if ($pun_updates['fail'])
+ $alert_items[] = ''.$lang_common['Updates'].' '.$lang_common['Updates failed'].'
';
+ else if (isset($pun_updates['version']) && isset($pun_updates['hotfix']))
+ $alert_items[] = ''.$lang_common['Updates'].' '.sprintf($lang_common['Updates version n hf'], $pun_updates['version']).'
';
+ else if (isset($pun_updates['version']))
+ $alert_items[] = ''.$lang_common['Updates'].' '.sprintf($lang_common['Updates version'], $pun_updates['version']).'
';
+ else if (isset($pun_updates['hotfix']))
+ $alert_items[] = ''.$lang_common['Updates'].' '.$lang_common['Updates hf'].'
';
+}
+
+($hook = get_hook('hd_alert')) ? eval($hook) : null;
+
+if (!empty($alert_items))
+{
+ ob_start();
+
+?>
+
+', $tpl_temp, $tpl_main);
+ ob_end_clean();
+}
+// END SUBST -
+
+
+// START SUBST -
+if ($pun_config['o_announcement'] == '1')
+ $tpl_main = str_replace('', ''."\n\t".'
'.($pun_config['o_announcement_heading'] != '' ? "\n\t\t".'
'.$pun_config['o_announcement_heading'].'
' : '')."\n\t\t".$pun_config['o_announcement_message']."\n\t".''."\n".'
'."\n", $tpl_main);
+// END SUBST -
+
+
+// START SUBST -
+ob_start();
+
+define('PUN_HEADER', 1);