What's new
Xen Factory

Register today to become a member! Once signed in, you'll be able to start purchasing our products, ask questions, request support and suggest new ideas!

  • We are aware that a no permission error was shown when you tried to purchase in the last 2 days, this is now fixed.

Suggestion Fixed template modifications fix

frybread

Member
member_view template is not compatible with other addons. The fix is to add $0 at the end.

_data\template_modifications.xml

find
Code:
  <modification type="public" template="member_view" modification_key="xfa_rm_dt_member_view_tab" description="Add member tab" execution_order="10" enabled="1" action="str_replace">
    <find><![CDATA[<!--[XF:tabs:end]-->]]></find>
    <replace><![CDATA[<xf:if is="{{ $xf.visitor.hasPermission('xfa_rm_dt', 'xfa_rm_dt_show') }} || ({{ $xf.visitor.hasPermission('xfa_rm_dt', 'xfa_rm_dt_show_own_down') }} && $user.user_id == $xf.visitor.user_id)">
    <a href="{{ link('members/downloads', $user) }}"
       class="tabs-tab"
       id="downloads"
       role="tab">{{ phrase('xfa_rm_dt_download_tracker') }}</a>
</xf:if>]]></replace>
  </modification>

replace
Code:
  <modification type="public" template="member_view" modification_key="xfa_rm_dt_member_view_tab" description="Add member tab" execution_order="10" enabled="1" action="str_replace">
    <find><![CDATA[<!--[XF:tabs:end]-->]]></find>
    <replace><![CDATA[<xf:if is="{{ $xf.visitor.hasPermission('xfa_rm_dt', 'xfa_rm_dt_show') }} || ({{ $xf.visitor.hasPermission('xfa_rm_dt', 'xfa_rm_dt_show_own_down') }} && $user.user_id == $xf.visitor.user_id)">
    <a href="{{ link('members/downloads', $user) }}"
       class="tabs-tab"
       id="downloads"
       role="tab">{{ phrase('xfa_rm_dt_download_tracker') }}</a>
</xf:if>
$0]]></replace>
  </modification>

This next one is not needed, but I like to keep $0 at the end:

find
Code:
  <modification type="public" template="member_view" modification_key="xfa_rm_dt_member_view_panes" description="Add member panes" execution_order="10" enabled="1" action="str_replace">
    <find><![CDATA[<!--[XF:tab_panes:end]-->]]></find>
    <replace><![CDATA[$0
<xf:if is="{{ $xf.visitor.hasPermission('xfa_rm_dt', 'xfa_rm_dt_show') }} || ({{ $xf.visitor.hasPermission('xfa_rm_dt', 'xfa_rm_dt_show_own_down') }} && $user.user_id == $xf.visitor.user_id)">
    <li data-href="{{ link('members/downloads', $user) }}" role="tabpanel" aria-labelledby="downloads">
        <div class="blockMessage">{{ phrase('loading...') }}</div>
    </li>
</xf:if>]]></replace>
  </modification>

replace
Code:
  <modification type="public" template="member_view" modification_key="xfa_rm_dt_member_view_panes" description="Add member panes" execution_order="10" enabled="1" action="str_replace">
    <find><![CDATA[<!--[XF:tab_panes:end]-->]]></find>
    <replace><![CDATA[
<xf:if is="{{ $xf.visitor.hasPermission('xfa_rm_dt', 'xfa_rm_dt_show') }} || ({{ $xf.visitor.hasPermission('xfa_rm_dt', 'xfa_rm_dt_show_own_down') }} && $user.user_id == $xf.visitor.user_id)">
    <li data-href="{{ link('members/downloads', $user) }}" role="tabpanel" aria-labelledby="downloads">
        <div class="blockMessage">{{ phrase('loading...') }}</div>
    </li>
</xf:if>
$0]]></replace>
  </modification>
 
Last edited:

Fred

Administrator
Staff member
Fixed in 2.1.1

If you have any issue please create a new thread, and if you like this addon, please let a review on xenforo.com
 
Top