Blame Identity/Models/Html/Punbb/footer.php

d6e8d8
d6e8d8
/***********************************************************************
d6e8d8
d6e8d8
  Copyright (C) 2002-2008  PunBB
d6e8d8
d6e8d8
  This file is part of PunBB.
d6e8d8
d6e8d8
  PunBB is free software; you can redistribute it and/or modify it
d6e8d8
  under the terms of the GNU General Public License as published
d6e8d8
  by the Free Software Foundation; either version 2 of the License,
d6e8d8
  or (at your option) any later version.
d6e8d8
d6e8d8
  PunBB is distributed in the hope that it will be useful, but
d6e8d8
  WITHOUT ANY WARRANTY; without even the implied warranty of
d6e8d8
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
d6e8d8
  GNU General Public License for more details.
d6e8d8
d6e8d8
  You should have received a copy of the GNU General Public License
d6e8d8
  along with this program; if not, write to the Free Software
d6e8d8
  Foundation, Inc., 59 Temple Place, Suite 330, Boston,
d6e8d8
  MA  02111-1307  USA
d6e8d8
d6e8d8
************************************************************************/
d6e8d8
d6e8d8
d6e8d8
// Make sure no one attempts to run this script "directly"
d6e8d8
if (!defined('PUN'))
d6e8d8
	exit;
d6e8d8
d6e8d8
$tpl_temp = trim(ob_get_contents());
d6e8d8
$tpl_main = str_replace('<pun_main>', $tpl_temp, $tpl_main);
d6e8d8
ob_end_clean();
d6e8d8
// END SUBST - <pun_main>
d6e8d8
d6e8d8
d6e8d8
// START SUBST - <pun_footer>
d6e8d8
ob_start();
d6e8d8
d6e8d8
?>
d6e8d8
d6e8d8
	

d6e8d8
	
d6e8d8
		
d6e8d8
d6e8d8
d6e8d8
// If no footer style has been specified, we use the default (only copyright/debug info)
d6e8d8
$footer_style = isset($footer_style) ? $footer_style : NULL;
d6e8d8
d6e8d8
if ($footer_style == 'index' || $footer_style == 'search')
d6e8d8
{
d6e8d8
	if (!$pun_user['is_guest'])
d6e8d8
	{
d6e8d8
		echo "\n\t\t\t".'
'."\n\t\t\t\t".'
'.$lang_common['Search links'].'
'."\n\t\t\t\t".'
'.$lang_common['Show recent posts'].'
'."\n";
d6e8d8
		echo "\t\t\t\t".'
'.$lang_common['Show unanswered posts'].'
'."\n";
d6e8d8
d6e8d8
		if ($pun_config['o_subscriptions'] == '1')
d6e8d8
			echo "\t\t\t\t".'
'.$lang_common['Show subscriptions'].'
'."\n";
d6e8d8
d6e8d8
		echo "\t\t\t\t".'
'.$lang_common['Show your posts'].'
'."\n\t\t\t".''."\n";
d6e8d8
	}
d6e8d8
	else
d6e8d8
	{
d6e8d8
		if ($pun_user['g_search'] == '1')
d6e8d8
		{
d6e8d8
			echo "\n\t\t\t".'
'."\n\t\t\t\t".'
'.$lang_common['Search links'].'
'.$lang_common['Show recent posts'].'
'."\n";
d6e8d8
			echo "\t\t\t\t".'
'.$lang_common['Show unanswered posts'].'
'."\n\t\t\t".''."\n";
d6e8d8
		}
d6e8d8
	}
d6e8d8
}
d6e8d8
else if ($footer_style == 'viewforum' || $footer_style == 'viewtopic')
d6e8d8
{
d6e8d8
	echo "\n\t\t\t".'
'."\n";
d6e8d8
d6e8d8
	// Display the "Jump to" drop list
d6e8d8
	if ($pun_config['o_quickjump'] == '1')
d6e8d8
	{
d6e8d8
		// Load cached quickjump
d6e8d8
		@include PUN_ROOT.'cache/cache_quickjump_'.$pun_user['g_id'].'.php';
d6e8d8
		if (!defined('PUN_QJ_LOADED'))
d6e8d8
		{
d6e8d8
			require_once PUN_ROOT.'include/cache.php';
d6e8d8
			generate_quickjump_cache($pun_user['g_id']);
d6e8d8
			require PUN_ROOT.'cache/cache_quickjump_'.$pun_user['g_id'].'.php';
d6e8d8
		}
d6e8d8
	}
d6e8d8
d6e8d8
	if ($footer_style == 'viewforum' && $is_admmod)
d6e8d8
		echo "\t\t\t".'

'.$lang_common['Moderate forum'].'

'."\n";
d6e8d8
	else if ($footer_style == 'viewtopic' && $is_admmod)
d6e8d8
	{
d6e8d8
		echo "\t\t\t".'
'.$lang_topic['Mod controls'].'
'.$lang_common['Delete posts'].'
'."\n";
d6e8d8
		echo "\t\t\t".'
'.$lang_common['Move topic'].'
'."\n";
d6e8d8
d6e8d8
		if ($cur_topic['closed'] == '1')
d6e8d8
			echo "\t\t\t".'
'.$lang_common['Open topic'].'
'."\n";
d6e8d8
		else
d6e8d8
			echo "\t\t\t".'
'.$lang_common['Close topic'].'
'."\n";
d6e8d8
d6e8d8
		if ($cur_topic['sticky'] == '1')
d6e8d8
			echo "\t\t\t".'
'.$lang_common['Unstick topic'].'
'."\n";
d6e8d8
		else
d6e8d8
			echo "\t\t\t".'
'.$lang_common['Stick topic'].'
'."\n";
d6e8d8
	}
d6e8d8
d6e8d8
	echo "\t\t\t".''."\n";
d6e8d8
}
d6e8d8
d6e8d8
?>
d6e8d8
d6e8d8
d6e8d8
// Display debug info (if enabled/defined)
d6e8d8
if (defined('PUN_DEBUG'))
d6e8d8
{
d6e8d8
	// Calculate script generation time
d6e8d8
	list($usec, $sec) = explode(' ', microtime());
d6e8d8
	$time_diff = sprintf('%.3f', ((float)$usec + (float)$sec) - $pun_start);
d6e8d8
	echo "\t\t\t".'

[ Generated in '.$time_diff.' seconds, '.$db->get_num_queries().' queries executed ]

'."\n";
d6e8d8
}
d6e8d8
d6e8d8
?>
d6e8d8
			
d6e8d8
		
d6e8d8
	
d6e8d8
d6e8d8
d6e8d8
Powered by PunBB
© Copyright 2002–2008 PunBB
d6e8d8
d6e8d8
d6e8d8
d6e8d8
d6e8d8
// End the transaction
d6e8d8
$db->end_transaction();
d6e8d8
d6e8d8
// Display executed queries (if enabled)
d6e8d8
if (defined('PUN_SHOW_QUERIES'))
d6e8d8
	display_saved_queries();
d6e8d8
d6e8d8
$tpl_temp = trim(ob_get_contents());
d6e8d8
$tpl_main = str_replace('<pun_footer>', $tpl_temp, $tpl_main);
d6e8d8
ob_end_clean();
d6e8d8
// END SUBST - <pun_footer>
d6e8d8
d6e8d8
d6e8d8
// Close the db connection (and free up any result data)
d6e8d8
$db->close();
d6e8d8
d6e8d8
// Spit out the page
d6e8d8
exit($tpl_main);