Added Link Us Block;
Fixed a small bug in user menu;
This commit is contained in:
84
root/portal/modules/portal_link_us.php
Normal file
84
root/portal/modules/portal_link_us.php
Normal file
@@ -0,0 +1,84 @@
|
||||
<?php
|
||||
/**
|
||||
* @package Portal - Link Us
|
||||
* @version $Id$
|
||||
* @copyright (c) 2009, 2010 Board3 Portal Team
|
||||
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
|
||||
*/
|
||||
|
||||
/**
|
||||
* @ignore
|
||||
*/
|
||||
if (!defined('IN_PHPBB'))
|
||||
{
|
||||
exit;
|
||||
}
|
||||
|
||||
/**
|
||||
* @package Clock
|
||||
*/
|
||||
class portal_link_us_module
|
||||
{
|
||||
/**
|
||||
* Allowed columns: Just sum up your options (Exp: left + right = 10)
|
||||
* top 1
|
||||
* left 2
|
||||
* center 4
|
||||
* right 8
|
||||
* bottom 16
|
||||
*/
|
||||
var $columns = 10;
|
||||
|
||||
/**
|
||||
* Default modulename
|
||||
*/
|
||||
var $name = 'LINK_US';
|
||||
|
||||
/**
|
||||
* Default module-image:
|
||||
* file must be in "{T_THEME_PATH}/images/portal/"
|
||||
*/
|
||||
var $image_src = 'portal_link_us.png';
|
||||
|
||||
/**
|
||||
* module-language file
|
||||
* file must be in "language/{$user->lang}/mods/portal/"
|
||||
*/
|
||||
var $language = 'portal_link_us_module';
|
||||
|
||||
function get_template_side($module_id)
|
||||
{
|
||||
global $config, $template, $user;
|
||||
|
||||
//doing the easy way ;)
|
||||
$u_link = generate_board_url();
|
||||
|
||||
// Assign specific vars
|
||||
$template->assign_vars(array(
|
||||
'LINK_US_TXT' => sprintf($user->lang['LINK_US_TXT'], $config['sitename']),
|
||||
'U_LINK_US' => '<a href="' . $u_link . '" ' . (($config['site_desc']) ? 'title="' . $config['site_desc'] . '"' : '' ) . '>' . (($config['sitename']) ? $config['sitename'] : $u_link ) . '</a>',
|
||||
));
|
||||
|
||||
return 'link_us_side.html';
|
||||
}
|
||||
|
||||
function get_template_acp($module_id)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* API functions
|
||||
*/
|
||||
function install($module_id)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
function uninstall($module_id)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
@@ -157,7 +157,7 @@ class portal_user_menu_module
|
||||
|
||||
function get_template_acp($module_id)
|
||||
{
|
||||
return false
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user