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

RM 1.1 Remove Latest Updates tab

Discussion in 'Resource Manager Support' started by JamesBrown, Oct 4, 2014.

  1. JamesBrown

    JamesBrown Well-Known Member

    Is this possible? Thanks
     
  2. Chris D

    Chris D XenForo Developer Staff Member

  3. JamesBrown

    JamesBrown Well-Known Member

    Hi Yes, keep the same order, but remove the latest tab. The resources we have are not updated.
     
  4. Chris D

    Chris D XenForo Developer Staff Member

    The tabs are in the resource_index template, this is the block of code that contains all of the tabs on the resource index:
    Code:
    <ol class="tabs">
        <li class="{xen:if '{$order} == "last_update"', active}"><a href="{xen:link resources, '', '_params={$pageNavParams}', 'order='}">{xen:phrase latest_updates}</a></li>
        <li class="{xen:if '{$order} == "resource_date"', active}"><a href="{xen:link resources, '', '_params={$pageNavParams}', 'order=resource_date'}">{xen:phrase newest_resources}</a></li>
        <li class="{xen:if '{$order} == "rating_weighted"', active}"><a href="{xen:link resources, '', '_params={$pageNavParams}', 'order=rating_weighted'}">{xen:phrase top_resources}</a></li>
        <li class="{xen:if '{$order} == "download_count"', active}"><a href="{xen:link resources, '', '_params={$pageNavParams}', 'order=download_count'}">{xen:phrase most_downloaded}</a></li>
    </ol>
     
  5. JamesBrown

    JamesBrown Well-Known Member

    Thanks Chris, I removed the latest updates tab, but now when you eneter the directory none of the tabs are active and its still sorted by latest updates. Would it be difficult to have the Newest Resource activated so on opening the directory its sorted by newest.
     
  6. Chris D

    Chris D XenForo Developer Staff Member

    I expected you would actually remove all tabs.

    You specifically said you didn't want to change the order and now you're saying you want to change the order...

    If you don't use updates then effectively, Latest Updates == Newest Resources so I recommend changing the tabs code to this:

    Code:
    <ol class="tabs">
        <li class="{xen:if '{$order} == "last_update"', active}"><a href="{xen:link resources, '', '_params={$pageNavParams}', 'order='}">{xen:phrase newest_resources}</a></li>
        <li class="{xen:if '{$order} == "rating_weighted"', active}"><a href="{xen:link resources, '', '_params={$pageNavParams}', 'order=rating_weighted'}">{xen:phrase top_resources}</a></li>
        <li class="{xen:if '{$order} == "download_count"', active}"><a href="{xen:link resources, '', '_params={$pageNavParams}', 'order=download_count'}">{xen:phrase most_downloaded}</a></li>
    </ol>
     
  7. JamesBrown

    JamesBrown Well-Known Member

    Sorry I thought you meant the order of the tabs. The actual resources I would like to show up as newest in date order. I'll try that code change. Cheers.
     

Share This Page