Site Links
Home
Features
Documentation
Pricing & Order
Members Area
Support Options
UBBDev.com
UBBWiki.com
Who's Online
5 registered (Gizmo, GregK, Iann128, SteveS, SD), 34 Guests and 16 Spiders online.
Key: Admin, Global Mod, Mod
Featured Member
Registered: 04/22/10
Posts: 5
Top Posters (30 Days)
Ruben 61
SD 52
Gizmo 48
gliderdad 33
Dunny 21
driv 18
dbremer 16
Mark S 13
Stan 12
Iann128 10
Latest Photos
OK Corral Shoot Out
Testing
Basildon Train Station
Basildon Town Centre looking from the rounderbout
Basildon Town Square
Page 1 of 2 1 2 >
Topic Options
#227001 - 06/03/09 02:41 AM Editing the Header Template to include a Wiki Link?
Realta Gaoth Offline
journeyman
Registered: 05/30/09
Posts: 54
On another forum, the header.tpl code is an almost exact mirror to the one I have currently on my new forum {different admin/owner, showing me the ropes}, but they have an older UBB version. I tried to match the coding to add a link to the header {between 'my stuff' and 'user list'} but it just messes up the entire forum and I'm not sure if there's any way to do this without causing an issue.
Top
Express Hosting
Express Hosting "We are the official hosting company of UBB.threads. Ask us about our free migration services to migrate your UBB.threads installation."
#227002 - 06/03/09 03:45 AM Re: Editing the Header Template to include a Wiki Link? [Re: Realta Gaoth]
Rick Offline
Post-a-holic
Registered: 06/04/06
Posts: 10164
Loc: Aberdeen, WA
It really depends on what you have in your header. If you can give a link or even post what you're putting in your header here, we can probably help.
Top
#227003 - 06/03/09 04:43 AM Re: Editing the Header Template to include a Wiki Link? [Re: Rick]
Realta Gaoth Offline
journeyman
Registered: 05/30/09
Posts: 54
code given as an example from admin friend on other board:

Click to reveal..

Code:
{* Script Version 7.2.2 *}

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html dir="{$lang.READ_DIRECTION}">
<head>
<meta name="generator" content="UBB.threads {$version}" />
{literal}
<style type="text/css">
.popup_menu a,
.popup_menu label { display: block; padding: 2px; cursor: pointer; }
.ubbcode-pre {
	font-family: monospace;
	white-space: pre;
}
pre {
margin: 0px;
}
</style>
{/literal}
{$headerinsert}
{$refresh}
<meta http-equiv="Content-Type" content="text/html; charset={$lang.CHARSET}" />
<link rel="stylesheet" href="{$stylesheet}" type="text/css" />
<link rel="shortcut icon" href="{$config.BASE_URL}/images/{$style_array.general}/favicon.ico" />
{$rss_feed}
{foreach from=$javascript item=script}
<script type="text/javascript" src="{$config.BASE_URL}/ubb_js/{$script}"></script>
{/foreach}
<script language="javascript" type="text/javascript">
var baseurl = "{$config.BASE_URL}";
var fullurl = "{$config.FULL_URL}";
var imagedir = "{$style_array.general}";
var myUid = '{$myid}'; // Don't get excited, you can't exploit this :D
var submitClicked = "{$lang.SUBMIT_CLICKED}";
var open_block = new Image();
open_block.src = "{$config.BASE_URL}/images/{$style_array.general}/toggle_open.gif";
var closed_block = new Image();
closed_block.src = "{$config.BASE_URL}/images/{$style_array.general}/toggle_closed.gif";
var loadingpreview = "{$lang.LOADING_PREVIEW}";
var today = '{$today}';
</script>
<title>{if $inputTitle}{$inputTitle|strip_tags} - {/if}{$config.COMMUNITY_TITLE}{if $powered} - {$powered} UBB.threads&trade;{/if}</title>
</head>
<body onload="{$onload}" onclick="{literal}if(event.which!=3){clearMenus(event)}{/literal}" {$onunload}>
<a name="top"></a>
{$headerfile}

{if $search_link}
<div id="active_popup" style="display: none;">
<table class="popup_menu">
<tr><td nowrap='nowrap' class="popup_menu_header">
{$lang.ACTIVE_TOPICS}
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}activetopics{$var_sep}range{$var_eq}1{$var_sep}type{$var_eq}t">{$lang.ACTIVE_24}</a>
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}activetopics{$var_sep}range{$var_eq}2{$var_sep}type{$var_eq}t">{$lang.ACTIVE_48}</a>
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}activetopics{$var_sep}range{$var_eq}7{$var_sep}type{$var_eq}t">{$lang.ACTIVE_7}</a>
</td></tr>
<tr><td nowrap='nowrap' class="popup_menu_header">
{$lang.ACTIVE_POSTS}
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}activetopics{$var_sep}range{$var_eq}1{$var_sep}type{$var_eq}p">{$lang.ACTIVE_24}</a>
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}activetopics{$var_sep}range{$var_eq}2{$var_sep}type{$var_eq}p">{$lang.ACTIVE_48}</a>
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}activetopics{$var_sep}range{$var_eq}7{$var_sep}type{$var_eq}p">{$lang.ACTIVE_7}</a>
</td></tr>
</table></div>
<script type="text/javascript">registerPopup("active_popup");</script>
{/if}

{if $myspace_link}
<div id="myspace_popup" style="display: none;">
<table class="popup_menu">
<tr><td nowrap='nowrap' class="popup_menu_header">
{$lang.MY_SPACE}
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}viewmessages">{$lang.MY_PRIVATES}</a>
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}editbasic">{$lang.EDIT_PROF}</a>
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}editdisplay">{$lang.EDIT_DISPLAY}</a>
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}myhome{$var_sep}n{$var_eq}1">{$lang.VIEW_WATCH}</a>
</td></tr>
<tr><td class="popup_menu_content">
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}userposts{$var_sep}id{$var_eq}{$myid}">{$lang.MY_POSTS}</a>
</td></tr>
</table></div>
<script type="text/javascript">registerPopup("myspace_popup");</script>
{/if}

<table border="0" align="center" width="{$config.TABLE_WIDTH}" cellpadding="0" cellspacing="0">
<tr>
<td>
{$tbopen}
<tr>
<td class="breadcrumbs">
<span style="float:right">{$welcome}
{if $mood && $config.ENABLE_MOODS}
<a title="{$lang.CHANGE_MOOD}" style="text-decoration: none" href="javascript: void(0);" onclick="javascript: window.open('{$config.BASE_URL}/ubbthreads.php?ubb=changemood','mood','toolbar=no,directories=no,location=no,scrollbars=yes,menubar=no,width=300,height=200')"> 
<img name="mood" src="{$config.BASE_URL}/images/{$style_array.mood}/{$mood}" style="vertical-align:middle" border="0" alt="{$lang.CHANGE_MOOD}" /> &darr;
</a>
{/if}
</span>
<span style="float:left">
{if $config.ENABLE_MAIN_PORTAL}
<a href="{$config.BASE_URL}/ubbthreads.php">{$config.COMMUNITY_TITLE}</a>
{else}
<a href="{$config.HOMEPAGE_URL}">{$config.HOMEPAGE_TITLE}</a>
{/if}
{if $breadcrumb}
 &raquo; {$breadcrumb}
{/if} 
</span>
</td>
</tr>
<tr>
<td class="navigation">
{if $new_user_link}
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}newuser">{$lang.NEW_USER}</a> &nbsp; &nbsp; &nbsp; 
{/if}
{if $cp_link}
<a href="{$config.BASE_URL}/admin/index.php">{$lang.ADMIN_MENU}</a> &nbsp; &nbsp;
{/if}
{if $config.ENABLE_MAIN_PORTAL}
<a href="{$config.BASE_URL}/ubbthreads.php">{$lang.PORTAL}</a> &nbsp; &nbsp;
{/if}
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}cfrm">{$lang.FORUM_LIST}</a> &nbsp; &nbsp; &nbsp; 
{if $myspace_link}
<span style="cursor: pointer;" id="myspace_control" onclick="showHideMenu('myspace_control','myspace_popup')">
<a href="javascript:void(0);">{$lang.MY_SPACE}</a>
<img style="vertical-align: middle" src="{$config.BASE_URL}/images/{$style_array.general}/toggle_open.gif" alt="" />
</span>
{$new_flasher}
 &nbsp; &nbsp; &nbsp;
{/if}
<a href="/pmwiki/pmwiki.php">Site Wiki</a>
&nbsp; &nbsp; &nbsp;   

<a href="http://www.lightsideofdarkness.com/pmwiki/pmwiki.php?n=Start.CharacterApplications">Character Applications</a>
&nbsp; &nbsp; &nbsp;   

{if $user_list}
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}showmembers">{$lang.USER_LIST}</a> &nbsp; &nbsp; &nbsp; 
{/if}
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}calendar">{$lang.CALENDAR}</a> &nbsp; &nbsp; &nbsp; 
{if $search_link}
<span style="cursor: pointer;" id="active_control" onclick="showHideMenu('active_control','active_popup')">
<a href="javascript:void(0);">{$lang.ACTIVE_TOPICS}</a>
<img style="vertical-align: middle" src="{$config.BASE_URL}/images/{$style_array.general}/toggle_open.gif" alt="" /> &nbsp; &nbsp; &nbsp; 
</span>
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}search">{$lang.TEXT_SEARCH}</a> &nbsp; &nbsp; &nbsp; 
{/if}
<a href="{$config.BASE_URL}/ubbthreads.php{$var_start}ubb{$var_eq}faq">{$lang.FAQ_TEXT}</a>
</td>
</tr>
{$tbclose}

</td>
</tr>
<tr>
<td>

<table border="0" width="100%" cellpadding="0" cellspacing="0" style="margin-top: -5px">



code in the present board:

Click to reveal..

Code:
{* Script Version 7.5.3 *}

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="{$lang.XML_LANG}" lang="{$lang.XML_LANG}" dir="{$lang.READ_DIRECTION}">
<head>
	<title>{if $inputTitle}{$inputTitle|strip_tags} - {/if}{if $powered}{$powered} UBB.threads&trade;{else}{$config.COMMUNITY_TITLE}{/if}</title>
	<meta name="generator" content="UBB.threads {$version}" />
	{$headerinsert}
	{$refresh}
	<meta http-equiv="Content-Type" content="text/html; charset={$lang.CHARSET}" />
	<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
	<link rel="stylesheet" href="{$config.BASE_URL}/styles/common.css?v={$version}" type="text/css" />
	<link rel="stylesheet" href="{$stylesheet}?v={$version}" type="text/css" />
	<link rel="shortcut icon" href="{$config.BASE_URL}/images/{$style_array.general}/favicon.ico" />
	{$rss_feed}
	<script type="text/javascript">
		// <![CDATA[
		var baseurl		= "{$config.BASE_URL}";
		var fullurl		= "{$config.FULL_URL}";
		var script		= "{ubb url="" full="true"}";
		var imagedir		= "{$style_array.general}";
		var myUid		= '{$myid}';
		var submitClicked 	= "{$lang.SUBMIT_CLICKED}";
		var open_block		= new Image();
		open_block.src		= baseurl + "/images/{$style_array.general}/toggle_open.gif";
		var closed_block	= new Image();
		closed_block.src	= baseurl + "/images/{$style_array.general}/toggle_closed.gif";
		var loadingpreview	= "{$lang.LOADING_PREVIEW}";
		var today		= '{$today}';
		var s_priv		= '{$s_priv}';
		// ]]>
	</script>
{foreach from=$javascript item=script}
	<script type="text/javascript" src="{$config.BASE_URL}/ubb_js/{$script}?v={$version}"></script>
{/foreach}

{if $config.MAX_WIDTH_IMAGE}
<style type="text/css">
.post_inner img {literal}{{/literal}
	max-width: {$config.MAX_WIDTH_IMAGE}px;
{literal}}{/literal}
</style>
{/if}

</head>
<body{if $onload} onload="{$onload}"{/if} onclick="{literal}if(event.which!=3){clearMenus(event)}{/literal}"{if $onunload} {$onunload}{/if}>
<a id="top"></a>

{if $admin_closed_message}
{$tbopen}
<tr><td bgcolor="red" align="center">
<span style="font-size: 12pt; font-weight: bold;">
FORUM IS CURRENTLY CLOSED!
</span>
</td></tr>
<tr>
<td class="alt-1">
{$closed_message}
</td>
</tr>
{$tbclose}
{/if}

<div id="content">
{$headerfile}

<div id="active_popup" style="display: none;">
	<table class="popup_menu">
		<tr>
			<td class="popup_menu_content"><a href="{ubb url="ubb=activetopics&range=7&type=t"}">{$lang.ACTIVE_TOPICS}</a></td>
		</tr>
		<tr>
			<td class="popup_menu_content"><a href="{ubb url="ubb=activetopics&range=7&type=p"}">{$lang.ACTIVE_POSTS}</a></td>
		</tr>
		<tr>
			<td class="popup_menu_content"><a href="{ubb url="ubb=activetopics&range=7&type=u"}">{$lang.ACTIVE_NO_ANSWERS}</a></td>
		</tr>
	</table>
</div>
<script type="text/javascript">
	registerPopup("active_popup");
</script>

{if $search_link}
<div id="search_popup" style="display: none">
	<form method="post" action="{ubb url=""}">
		<input type="hidden" name="ubb" value="dosearch" />
		<input type="hidden" name="daterange" value="0" />
		<input type="hidden" name="where" value="bodysub" />
		<input type="hidden" name="fromsearch" value="1" />
		<input type="hidden" name="checkwords" value="1" />

		<table class="popup_menu">
			<tr>
				<td nowrap='nowrap' class="popup_menu_header">{$lang.SEARCH_HEADER}</td>
			</tr>
			<tr>
				<td class="popup_menu_content noclose">
					<label>
						<input type="text" name="Words" class="form-input" />
						<input type="submit" name="textsearch" value="{$lang.GO_BUTTON}" class="form-button" />
					</label>
				</td>
			</tr>
			<tr>
				<td class="popup_menu_content"><a href="{ubb url="ubb=search"}">{$lang.ADVANCED_BUTTON}</a></td>
			</tr>
		</table>
	</form>
</div>
<script type="text/javascript">
	registerPopup("search_popup");
</script>
{/if}

{if $myspace_link == 1}
<div id="myspace_popup" style="display: none;">
<table class="popup_menu">
<tr><td class="popup_menu_content"><a href="{ubb url="ubb=viewmessages"}">{$lang.MY_PRIVATES}</a></td></tr>
<tr><td class="popup_menu_content"><a href="{ubb url="ubb=editbasic"}">{$lang.EDIT_PROF}</a></td></tr>
<tr><td class="popup_menu_content"><a href="{ubb url="ubb=editdisplay"}">{$lang.EDIT_DISPLAY}</a></td></tr>
<tr><td class="popup_menu_content"><a href="{ubb url="ubb=myhome&n=1"}">{$lang.VIEW_WATCH}</a></td></tr>
<tr><td class="popup_menu_content"><a href="{ubb url="ubb=showprofile&User=`$myid`"}">{$lang.VIEW_PROF}</a></td></tr>
<tr><td class="popup_menu_content"><a href="{ubb url="ubb=userposts&id=`$myid`"}">{$lang.MY_POSTS}</a></td></tr>
<tr><td class="popup_menu_content"><a href="{ubb url="ubb=mybuddies"}">{$lang.MY_BUDDIES}</a></td></tr>
{if $config.MY_FEEDS}
<tr><td class="popup_menu_content"><a href="{ubb url="ubb=myfeeds&show=1"}">{$lang.MY_FEEDS}</a></td></tr>
{/if}
<tr><td class="popup_menu_content"><a href="{ubb url="ubb=subscriptions"}">{$lang.MY_SUBS}</a></td></tr>
<tr><td class="popup_menu_content"><a href="{ubb url="ubb=mycookies"}">{$lang.MYCOOKIES}</a></td></tr>
</table></div>
<script type="text/javascript">registerPopup("myspace_popup");</script>
{/if}

<table align="center" width="{$config.TABLE_WIDTH}" cellpadding="0" cellspacing="0">
<tr>
<td>
{$tbopen}
<tr>
<td class="breadcrumbs">
<span style="float:right">{$welcome}
{if $mood && $config.ENABLE_MOODS}
<span title="{$lang.CHANGE_MOOD}" style="cursor: pointer" onclick="showChromeless('{ubb url="ubb=changemood"}','mood',400,300);">
<img name="mood" src="{$config.BASE_URL}/images/{$style_array.mood}/{$mood}" style="vertical-align:middle" alt="{$lang.CHANGE_MOOD}" /> &darr;
</span>
{/if}
</span>
<span style="float:left">
{if $config.ENABLE_MAIN_PORTAL}
<a href="{ubb url=""}">{$config.COMMUNITY_TITLE}</a>
{else}
<a href="{$config.HOMEPAGE_URL}">{$config.HOMEPAGE_TITLE}</a>
{/if}
{if $breadcrumb}
 &raquo; {$breadcrumb}
{/if}
</span>
</td>
</tr>
<tr>
<td class="navigation">
{if $new_user_link}
<a href="{ubb url="ubb=newuser"}">{$lang.NEW_USER}</a> &nbsp;&nbsp;
{/if}
{if $cp_link}
<a href="{$config.BASE_URL}/admin/index.php">{$lang.ADMIN_MENU}</a> &nbsp;&nbsp;
{/if}
{if $config.ENABLE_MAIN_PORTAL}
<a href="{ubb url=""}">{$lang.PORTAL}</a> &nbsp; &nbsp;
{/if}
<a href="{ubb url="ubb=cfrm"}">{$lang.FORUM_LIST}</a> &nbsp;&nbsp;
{if $myspace_link == 1}
<span style="cursor: pointer;" id="myspace_control" onclick="showHideMenu('myspace_control','myspace_popup')">
<a href="javascript:void(0);">{$lang.MY_SPACE}</a>
<img style="vertical-align: middle" src="{$config.BASE_URL}/images/{$style_array.general}/toggle_open.gif" alt="" />
</span>
{elseif $myspace_link == 2}
<a href="{ubb url="ubb=viewmessages"}">{$lang.MY_SPACE}</a>
{/if}
{$new_flasher} &nbsp;&nbsp;&nbsp;
{if $user_list}
<a href="{ubb url="ubb=showmembers"}">{$lang.USER_LIST}</a> &nbsp;&nbsp;&nbsp;
{/if}
{if $config.CALENDAR}
<a href="{ubb url="ubb=calendar"}">{$lang.CALENDAR}</a> &nbsp;&nbsp;&nbsp;
{/if}
<span style="cursor: pointer;" id="active_control" onclick="showHideMenu('active_control','active_popup')">
<a href="javascript:void(0);">{$lang.ACTIVE_TOPICS}</a>
<img style="vertical-align: middle" src="{$config.BASE_URL}/images/{$style_array.general}/toggle_open.gif" alt="" />
</span> &nbsp;&nbsp;&nbsp;
{if $search_link}
<span style="cursor: pointer;" id="search_control" onclick="showHideMenu('search_control','search_popup')">
<a href="javascript:void(0);">{$lang.TEXT_SEARCH}</a>
<img style="vertical-align: middle" src="{$config.BASE_URL}/images/{$style_array.general}/toggle_open.gif" alt="" />
</span> &nbsp;&nbsp;&nbsp;
{/if}
<a href="{ubb url="ubb=faq"}">{$lang.FAQ_TEXT}</a>
</td>
</tr>
{$tbclose}

</td>
</tr>
<tr>
<td>
<table width="100%" cellpadding="0" cellspacing="0" style="margin-top: -5px">



links/URLs desired for inclusion:

Site UBB.Wiki {directly to the right of 'my stuff' preferably}
http://illusionarylabyrinth.net/pmwiki/pmwiki.php

Character Applications {directly to the right of 'site UBB.Wiki', directly to the left of 'user list' preferably}
http://illusionarylabyrinth.net/pmwiki/pmwiki.php?n=Start.CharacterApplications
Top
#227007 - 06/03/09 04:42 PM Re: Editing the Header Template to include a Wiki Link? [Re: Realta Gaoth]
Ruben Offline

Registered: 12/20/03
Posts: 4268
Loc: Lutz,FL
HERE is a post that may help you get started
_________________________
Blue Man Group
Top
#227008 - 06/03/09 05:05 PM Re: Editing the Header Template to include a Wiki Link? [Re: Ruben]
Ruben Offline

Registered: 12/20/03
Posts: 4268
Loc: Lutz,FL
Actually it is fairy simple using the post I referenced.
In Template: header.tpl
Just above
Code:
{if $user_list}
and below
Code:
{$new_flasher} &nbsp;&nbsp;&nbsp;

Insert
Code:
<a href="http://illusionarylabyrinth.net/pmwiki/pmwiki.php">Site WIKI</a>&nbsp;&nbsp;&nbsp; 
<a href="http://illusionarylabyrinth.net/pmwiki/pmwiki.php?n=Start.CharacterApplications">Applications</a>&nbsp;&nbsp;&nbsp; 


Of course I don't know what version you are using but that should be fairly close.
_________________________
Blue Man Group
Top
#227014 - 06/03/09 05:59 PM Re: Editing the Header Template to include a Wiki Link? [Re: Ruben]
Realta Gaoth Offline
journeyman
Registered: 05/30/09
Posts: 54
You're a DOLL. I feel rather... foolish now that I look at it because it is really simple. But thank you for the help!
Top
#227015 - 06/03/09 06:02 PM Re: Editing the Header Template to include a Wiki Link? [Re: Realta Gaoth]
Ruben Offline

Registered: 12/20/03
Posts: 4268
Loc: Lutz,FL
No problem. If you use absolute paths to do this it will reference the default paths, So you were probably not including http://www.blabla
_________________________
Blue Man Group
Top
#235492 - 03/11/10 09:20 AM Re: Editing the Header Template to include a Wiki Link? [Re: Rick]
lightningrod Offline
enthusiast
Registered: 10/14/09
Posts: 275
Originally Posted By: Rick
It really depends on what you have in your header. If you can give a link or even post what you're putting in your header here, we can probably help.



Rick, I want to create a script called: selfsearch.inc.php

And throw it in the scripts directory of the server

And make: 'Self Search' appear in the Header pointing to that script

Between the User List and Calendar


And how I can have this Self Search link appear only to a user that is logged in?
Top
#235493 - 03/11/10 10:29 AM Re: Editing the Header Template to include a Wiki Link? [Re: lightningrod]
Chosen Offline
member
Registered: 01/26/05
Posts: 194
Loc: Cincinnati, OH
There is a more complete way to do this but I'll give you my easy way to do it. First off I only have the User List available to people that are logged in. So if that works for you then just disable guests from viewing it. Then put the new link in the {if $user_list} section before the {/if} line.
Top
#235494 - 03/11/10 10:32 AM Re: Editing the Header Template to include a Wiki Link? [Re: Chosen]
lightningrod Offline
enthusiast
Registered: 10/14/09
Posts: 275
Originally Posted By: Chosen
There is a more complete way to do this but I'll give you my easy way to do it. First off I only have the User List available to people that are logged in. So if that works for you then just disable guests from viewing it. Then put the new link in the {if $user_list} section before the {/if} line.



Thank you, but I don't even know how to do the first part


To make a 'Self Search' link appear in the Header, pointing to that (new) script

Between the User List and Calendar


?


Top
#235498 - 03/11/10 11:28 AM Re: Editing the Header Template to include a Wiki Link? [Re: lightningrod]
Chosen Offline
member
Registered: 01/26/05
Posts: 194
Loc: Cincinnati, OH
I think the user list is only viewable to logged in used as default, but if not here is how to get there. First, go to your control panel. Click "Group Management" under "Forums" section in the left nav. Then on the line that is for "Guests" click "Site". Make sure that the first box "Can view the Member List" is set to 0. If not, then change it and hit the "Update this Group's Permissions" button at the bottom.

Now to edit the header click "Templates" under the "Display Options" section in the left nav. Once you are on the template editor page scroll down the list until you see header.tpl. Select it and then hit the "Edit Selected Template" button.

Copy the contents of the original template into notepad so that you'll have it in case something goes wrong.

I have one header that is already edited so this may not be the exact thing to look for but try searching for a line that has the following on it:
Code:
<a href="{ubb url="ubb=showmembers"}">{$lang.USER_LIST}</a>

Then add your link on a new line below it.

Does that help? Feel free to ask more questions.

Also, realize that any changes you make to the templates will have to be reapplied whenever version 8 comes out. Make sure you keep a list of things to change whenever you upgrade.
Top
#235502 - 03/11/10 11:53 AM Re: Editing the Header Template to include a Wiki Link? [Re: Chosen]
SD Online   partay
Registered: 04/19/07
Posts: 4031
Loc: SoCal, USA
whenever you make a modification (suggestion here), add a comment to the file..

for me in .tpl (templates), i add {* SD:Mod - reason for modification *}

for php files, i add // SD:Mod - reason for modification

this allows for a utility like grep (free) to just search for any file with "SD:Mod" in it as a reminder.

of course Beyond Compare (not a free utility) will also note any differences as well..

it's just good to put in an indicator of sorts in any file that you touched it and for what reason and where.. :2cents:
_________________________

Threads tutorials . Threads & Wordpress experts . UBB resume

If I you, click this link as to why
Top
#235516 - 03/11/10 02:03 PM Re: Editing the Header Template to include a Wiki Link? [Re: Chosen]
lightningrod Offline
enthusiast
Registered: 10/14/09
Posts: 275
Thanks guys. It didn't work though

Nothing happened. It's blank

I added this in the header.tpl


Code:
{if $user_list}
<a href="{ubb url="ubb=showmembers"}">{$lang.USER_LIST}</a> &nbsp;&nbsp;&nbsp;
{/if}

{* LR:Mod - reason for modification - self search link *}
<a href="{ubb url="ubb=selfsearch"}">{$lang.SELF_SEARCH}</a>

{if $config.CALENDAR}
<a href="{ubb url="ubb=calendar"}">{$lang.CALENDAR}</a> &nbsp;&nbsp;&nbsp;
{/if}



I copied activetopics.inc.php and renamed it selfsearch.inc.php and uploaded it into the scripts directory on the server
Top
#235517 - 03/11/10 02:28 PM Re: Editing the Header Template to include a Wiki Link? [Re: lightningrod]
Chosen Offline
member
Registered: 01/26/05
Posts: 194
Loc: Cincinnati, OH
First thing is that it will show up for anyone if you have it in that spot. If you only want it to show up put it before the {/if} after the User List link.

In your link you have it as {$lang.SELF_SEARCH}. This would work if you created an entry in the language editor. The easy way is to just use "Self Search" instead of {$lang.SELF_SEARCH}.

If you want to add it to your language file you would need to go to "Languages" under "Display Options." Then click the "Language Editor" tab. To the right of 'Choose Specific Language File:" scroll down until you see generic.php. Select that and hit go. Scroll down to the bottom of the page and enter a new key which will be
key = SELF_SEARCH
string = Self Search

That is a lot of extra work just to get the name in there though if you are only going to use it in the one place.

That will get the link to show up, but I don't think the script will work as is. I guess how to set that up would work better at UBBDev, which I see you already have a couple threads about.
Top
#235518 - 03/11/10 02:30 PM Re: Editing the Header Template to include a Wiki Link? [Re: lightningrod]
Ruben Offline

Registered: 12/20/03
Posts: 4268
Loc: Lutz,FL
Well to start with if you only want registered users to see it it needs to be moved up a bit.
Php Code:
{if $user_list}
<a href="{ubb url="ubb=showmembers"}">{$lang.USER_LIST}</a> &nbsp;&nbsp;&nbsp;
{/if}

{* LR:Mod - reason for modification - self search link *}
<a href="{ubb url="ubb=selfsearch"}">{$lang.SELF_SEARCH}</a>
 


Move it above the (/if) to:

Php Code:
{if $user_list}
<a href="{ubb url="ubb=showmembers"}">{$lang.USER_LIST}</a> &nbsp;&nbsp;&nbsp;
{* LR:Mod - reason for modification - self search link *}
<a href="{ubb url="ubb=selfsearch"}">{$lang.SELF_SEARCH}</a>
{/if}
 


Why is it blank could be several items.
Such as does the language file key self_search have any text in it so at least something shows.
Should have been added to the generic.php file
Key: SELF_SEARCH
String: Self Search.
Then the question is does the actual script work.
_________________________
Blue Man Group
Top
#235519 - 03/11/10 02:38 PM Re: Editing the Header Template to include a Wiki Link? [Re: Ruben]
lightningrod Offline
enthusiast
Registered: 10/14/09
Posts: 275
Thanks guys, I did exactly what you said here

It still shows up when I log out (but that is not a major problem for me)


But there is a weird space between Forum List and User List

?


Ok, that space between Forum List and User List is only there when I'm logged out



Ok nevermind, maybe it's because My_Stuff disappears when I log out, and I never noticed that space in between before


Edited by lightningrod (03/11/10 02:43 PM)
Top
#235520 - 03/11/10 02:48 PM Re: Editing the Header Template to include a Wiki Link? [Re: lightningrod]
Ruben Offline

Registered: 12/20/03
Posts: 4268
Loc: Lutz,FL
It will show because you allow guests to see the user list.
Control Panel » Group Management »
Guests Site Permissions
First option is
Can view the Member List
set it to 0 for guests.
Then both the user list and self search will only be visible when logged in as a user.

BTW that space may be due to a reserved spot for the message indicator.


Edited by Ruben (03/11/10 02:50 PM)
Edit Reason: added BTW
_________________________
Blue Man Group
Top
#235521 - 03/11/10 02:52 PM Re: Editing the Header Template to include a Wiki Link? [Re: Ruben]
lightningrod Offline
enthusiast
Registered: 10/14/09
Posts: 275
Originally Posted By: Ruben
It will show because you allow guests to see the user list.
Control Panel » Group Management »
Guests Site Permissions
First option is
Can view the Member List
set it to 0 for guests.
Then both the user list and self search will only be visible when logged in as a user.



Thanks. I want Guests to see the User List


How can I put it between My_Stuff and User List, instead?


Or between Calender and Active_Topics?


Can I make the Calender disappear for Guests?


Edited by lightningrod (03/11/10 02:58 PM)
Top
#235522 - 03/11/10 02:59 PM Re: Editing the Header Template to include a Wiki Link? [Re: lightningrod]
Ruben Offline

Registered: 12/20/03
Posts: 4268
Loc: Lutz,FL
move it above the:
{if $user_list}
_________________________
Blue Man Group
Top
#235523 - 03/11/10 03:01 PM Re: Editing the Header Template to include a Wiki Link? [Re: Ruben]
lightningrod Offline
enthusiast
Registered: 10/14/09
Posts: 275
Originally Posted By: Ruben
move it above the:
{if $user_list}



It didn't work between My_Stuff and User List

It disappeared

I can try between Calender and Active Topics


But where can I make the Calender disappear for Guests?


Ok I'm going to leave it like this for now. There is no other way. If I ever want it to disappear for Guests I'll just put it before the User List and make the User List disappear for Guests


thanks


Edited by lightningrod (03/11/10 03:08 PM)
Top
Page 1 of 2 1 2 >



Moderator:  AllenAyres, Harold, Ian, Ron M 
Shout Box

Today's Birthdays
No Birthdays
Recent Topics
Edit Post
by Bert
Today at 01:19 PM
A positive note
by SteveS
Yesterday at 09:36 PM
How to locate links to particular site if they are only used in images?
by Conrad
02/10/12 09:41 PM
Pictures not displaying
by Marker23
02/09/12 10:04 PM
Issue with logging out constantly
by Flanuva
02/09/12 07:05 PM
Forum Stats
10214 Members
36 Forums
33668 Topics
180918 Posts

Max Online: 978 @ 06/24/07 11:19 PM
Random Image