1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Creating new website tabs and links

Discussion in 'XenForo Questions and Support' started by Ryan Kent, Feb 21, 2011.

  1. Ryan Kent

    Ryan Kent Well-Known Member

    I would like to create a new tab (Home, Forums, Members,...sry not sure if "tab" is the correct term but best I could come up with!) on my forums. Can anyone share the process? Create a new Page and ???

    Also, underneath the tabs there are various ?links (again, not sure of the correct term...for Forums there is Mark All Forums Read, Search Forums, Watched Threads, etc). Under my Members tab I was thinking of creating a link for a Staff page. Can anyone share how I would do such?

    I do have XenPorta installed if that is helpful, but not sure if it's best to use a native XF method or XenPorta.
  2. Brogan

    Brogan XenForo Moderator Staff Member

    To create a new link on the upper navigation bar, you need to edit the navigation template.
    For example, this tab will appear between members and help:
    <!-- my tabs -->
    <xen:if is="{$visitor.user_id}">
    <li class="navTab PopupClosed"><a href="{xen:link account/upgrades}" class="navLink">{xen:phrase account_upgrades}</a></li>
    <!-- help -->

    To create a link on the lower navigation bar, again you need to edit the navigation template, in a different place this time.
    For example this link will appear on the Help tab in the dropdown and on the lower navigation bar (just below/after the Trophies link) when the Help tab is clicked:
    <li><a href="{xen:link help/trophies}">{xen:phrase trophies}</a></li>
    <li><a href="{xen:link pages/staff}">{xen:phrase cta_staff}</a></li>
    radu81, Morgain, Luke B and 3 others like this.
  3. ragtek

    ragtek Guest

  4. Ryan Kent

    Ryan Kent Well-Known Member

    Thank you Brogan!

    ragtek, I appreciate that link as well. For some reason I never noticed that particular forum section. I'll certainly spend some time with it this week.
  5. James33

    James33 Member

    Hi Borgan ,

    When I change the phrase account_upgrades I keep getting syntax error , I try to replace account_upgrades to Live Webcam but I cannot save it keeps receiving syntax error any help ?
  6. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    There cannot be a space in the phrase name. But if you want to just hard-code the text and not use phrases then you need to remove the entire {xen:phrase ...} piece and just type in the text.

    Also, consider using this addon if you want to add nav tabs:


    It is a better solution than a template edit.
    James33 likes this.
  7. James33

    James33 Member

    Great Jake , I removed the xen pahrase and its fixed now but now I can see that above link viewable only by members I want this link to be public , how do i do it ?

  8. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    Remove the condition around it:

    <xen:if is="{$visitor.user_id}">

Share This Page