PDA

View Full Version : How to add "Home" Button to my forums?


MaXimus
11-16-2011, 10:06 AM
How can I add a Home Button (as shown below in the image) to have it link to my main website?

http://img137.imageshack.us/img137/8078/capturehfk.png (http://imageshack.us/photo/my-images/137/capturehfk.png/)

My main website URL is: http://bbmatrix.net (just in-case there was some code that you needed to give me)

Thanks

My forums are running on the latest official vBulletin v4.1.8

kh99
11-16-2011, 12:17 PM
You could do this: edit the navbar template and add the part in red (this section is at the very top of the template code):

<div id="navbar" class="navbar">
<ul id="navtabs" class="navtabs floatcontainer<vb:if condition="$show['member'] AND $notifications_total"> notify</vb:if>">
{vb:raw template_hook.navtab_start}
<vb:if condition="!$vboptions['selectednavtab'] AND THIS_SCRIPT != 'search'">
<li><a class="navtab" href="bbmatrix.net">Home</a></li>
<li class="selected"><a class="navtab" href="{vb:link forumhome}">{vb:rawphrase forum}</a>

MaXimus
11-16-2011, 12:35 PM
You could do this: edit the navbar template and add the part in red (this section is at the very top of the template code):

<div id="navbar" class="navbar">
<ul id="navtabs" class="navtabs floatcontainer<vb:if condition="$show['member'] AND $notifications_total"> notify</vb:if>">
{vb:raw template_hook.navtab_start}
<vb:if condition="!$vboptions['selectednavtab'] AND THIS_SCRIPT != 'search'">
<li><a class="navtab" href="bbmatrix.net">Home</a></li>
<li class="selected"><a class="navtab" href="{vb:link forumhome}">{vb:rawphrase forum}</a>

Thank you for your reply

When I added the code in red,

The Home Button did appear BUT, it takes me to >>> http://bbmatrix.net/forums/bbmatrix.net

which is an invalid URL obviously, why is it having the bbmatrix.net/forums as a prefix?

I just want it to direct to http://bbmatrix.net

Thank you

--------------- Added 1321450962 at 1321450962 ---------------

Ahh I fixed it!

Had to change the code from:

<li><a class="navtab" href="bbmatrix.net">Home</a></li>

to

<li><a class="navtab" href="http://bbmatrix.net">Home</a></li>


That was simple!

Thank you very much for guiding me! I really appreciate it!

kh99
11-16-2011, 12:45 PM
Ahh I fixed it!...


That was my fault, you did post the url you want to go to and I didn't use it. Anyway, glad you got it working.

MaXimus
11-16-2011, 01:02 PM
That was my fault, you did post the url you want to go to and I didn't use it. Anyway, glad you got it working.

Cheers man!

Thanks for your help!

vbuser70
11-18-2011, 07:40 AM
You could do this: edit the navbar template and add the part in red (this section is at the very top of the template code):


<li><a class="navtab" href="bbmatrix.net">Home</a></li>


Can you tell me, what do I need to use instead of "Home" if I want to have a variable instead of a text string (so I can use different button names for different languages) ?

Thanks in advance !

kh99
11-18-2011, 10:12 AM
Can you tell me, what do I need to use instead of "Home" if I want to have a variable instead of a text string (so I can use different button names for different languages) ?

Thanks in advance !

You just need to add a phrase in the phrase manager (use Phrase Type GLOBAL). Then in the navbar template, use {vb:rawphrase varname}, where "varname" is the Varname you entered when you created the phrase. Then you should be able to add translations for all your languages.

vbuser70
11-18-2011, 03:50 PM
You just need to add a phrase in the phrase manager (use Phrase Type GLOBAL). Then in the navbar template, use {vb:rawphrase varname}, where "varname" is the Varname you entered when you created the phrase. Then you should be able to add translations for all your languages.

It's exactly what I was asking for, thank you !

vbuser70
11-25-2011, 09:04 AM
Just discovered my buttons disappear when I go to Blogs, how to have them displaying there as well ?

MaXimus
04-03-2012, 06:27 AM
thanks a lot! great tips