UseBB Community

The official board for UseBB help and discussion

UseBB Community » Documentation, Tips & Tricks » Adding links to the menu

Adding links to the menu

Page: 1

Author Post
Developer
Registered: Apr 2004
Posts: 2180
Location: Belgium
Adding a link to the top menu

- Open templates/default/global.tpl.php in your text editor. If you use another template, replace default with your template name.
- Look for <div id="topmenu"><ul>. This is an unordered list.
- Add an item to this list with this format:
<li><a href="{url}">{title}</a></li>

- Replace {url} and {title} with the link URL and title.
- Save the file and verify the changes on your forum.

Adding a forum link to the top menu

The top menu can be extended with a few additional inner links for member list, staff list, RSS feed and statistics.

To add a link, enter any of the following codes in the unordered list (see above).

<li><a href="{link_memberlist}">{l_MemberList}</a></li>

<li><a href="{link_stafflist}">{l_StaffList}</a></li>

<li><a href="{link_rss}">{l_RSSFeed}</a></li>

<li><a href="{link_stats}">{l_Statistics}</a></li>


Adding a link to the link bar below

- Open sources/page_head.php in your text editor.
- Look for $template->add_global_vars(array(.
- Before, add
$link_bar[] = '<a href="{url}">{title}</a>';

- Replace {url} and {title} with the link URL and title.
- Save the file and verify the changes on your forum.

Note
In all cases, content is enclosed in single quotes ('). If you intend to use single quotes, you will need to escape them by adding a backlash (\').
_______________
--Dietrich (developer)
UseBB roadmap, dev mailing list & weblog
Member
Registered: Jun 2007
Posts: 122
Location: Gatineau, QC, Canada
<li><a href="{url}">{title}</a></li>


Works great but is there a way to make that new link for registered members only?

Cheers,
Gene
:)
Developer
Registered: Apr 2004
Posts: 2180
Location: Belgium
No, because there are no conditionals possible in UseBB 1 templates.
_______________
--Dietrich (developer)
UseBB roadmap, dev mailing list & weblog
Member
Registered: Jun 2007
Posts: 122
Location: Gatineau, QC, Canada
Dietrich wrote
No, because there are no conditionals possible in UseBB 1 templates.


OK, Dietrich, thanks.

BTW, Congrats for ver. 1.0.7.

Cheers,
Gene
:D

Page: 1

UseBB Community » Documentation, Tips & Tricks » Adding links to the menu

UseBB Community is powered by UseBB 1 Forum Software