FoP
Member
A number of tabs in the What's New menu aren't used so I wanted to remove them. For the sub navigation menu that's easily done in Navigation. But not so for the horizontal row on the board.
So I looked at the What's New wrapper. I wanted to remove New Profile posts, New Media comments and New Resources. However, only New Profile posts are listed in the wrapper. So I tried removing all the "XF:links" stuff, which got rid of the three tabs, but also of New Media, which we do want. So I brought that back into the wrapper. I also changed the order of the tabs.
It all works well, I'm not getting any errors, so I assume I did it right. But I would still like confirmation of this. The relevant bit in the What's New wrapper now looks like this (I also removed the second What's New title). Is this okay?
<xf:macro id="links" arg-pageSelected="!" arg-baseClass="!" arg-selectedClass="!">
<a class="{$baseClass} {{ $pageSelected == 'new_thread' ? {$selectedClass} : '' }}" href="{{ link('whats-new/posts') }}" rel="nofollow">{{ phrase('new_posts') }}</a>
<a class="{$baseClass} {{ $pageSelected == 'xfmg_new_media' ? {$selectedClass} : '' }}" href="{{ link('whats-new/media') }}" rel="nofollow">{{ phrase('xfmg_new_media') }}</a>
<xf:if is="$xf.options.enableNewsFeed">
<xf:if is="$xf.visitor.user_id">
<a class="{$baseClass} {{ $pageSelected == 'news_feed' ? {$selectedClass} : '' }}" href="{{ link('whats-new/news-feed') }}" rel="nofollow">{{ phrase('your_news_feed') }}</a>
</xf:if>
<a class="{$baseClass} {{ $pageSelected == 'latest_activity' ? {$selectedClass} : '' }}" href="{{ link('whats-new/latest-activity') }}" rel="nofollow">{{ phrase('latest_activity') }}</a>
</xf:if>
<a class="{$baseClass} {{ $pageSelected == 'featured' ? {$selectedClass} : '' }}" href="{{ link('featured') }}">{{ phrase('featured_content') }}</a>
</xf:macro>
So I looked at the What's New wrapper. I wanted to remove New Profile posts, New Media comments and New Resources. However, only New Profile posts are listed in the wrapper. So I tried removing all the "XF:links" stuff, which got rid of the three tabs, but also of New Media, which we do want. So I brought that back into the wrapper. I also changed the order of the tabs.
It all works well, I'm not getting any errors, so I assume I did it right. But I would still like confirmation of this. The relevant bit in the What's New wrapper now looks like this (I also removed the second What's New title). Is this okay?
<xf:macro id="links" arg-pageSelected="!" arg-baseClass="!" arg-selectedClass="!">
<a class="{$baseClass} {{ $pageSelected == 'new_thread' ? {$selectedClass} : '' }}" href="{{ link('whats-new/posts') }}" rel="nofollow">{{ phrase('new_posts') }}</a>
<a class="{$baseClass} {{ $pageSelected == 'xfmg_new_media' ? {$selectedClass} : '' }}" href="{{ link('whats-new/media') }}" rel="nofollow">{{ phrase('xfmg_new_media') }}</a>
<xf:if is="$xf.options.enableNewsFeed">
<xf:if is="$xf.visitor.user_id">
<a class="{$baseClass} {{ $pageSelected == 'news_feed' ? {$selectedClass} : '' }}" href="{{ link('whats-new/news-feed') }}" rel="nofollow">{{ phrase('your_news_feed') }}</a>
</xf:if>
<a class="{$baseClass} {{ $pageSelected == 'latest_activity' ? {$selectedClass} : '' }}" href="{{ link('whats-new/latest-activity') }}" rel="nofollow">{{ phrase('latest_activity') }}</a>
</xf:if>
<a class="{$baseClass} {{ $pageSelected == 'featured' ? {$selectedClass} : '' }}" href="{{ link('featured') }}">{{ phrase('featured_content') }}</a>
</xf:macro>
Last edited: