Your username here MUST MATCH your XenForo username (connected to your XF license).

    Once you have registered here, then you need to start a conversation at xenforo.com w/Bob and provide the following:
    1. Your XenForo License Validation Token
    2. The Domain Name associated with the License
    NOTE: Your account will be validated once ALL requirements are verified/met. Thank you for your patience.

Hook location for widget?

Discussion in 'Showcase Support' started by kontrabass, Mar 21, 2015.

  1. kontrabass

    kontrabass Member AMS Premium CAS Premium RMS Premium SC Premium

    I'm looking for a way to add a javascript advert (from skimlinks) on my showcase_item pages. I can easily add a widget to the nflj_showcase_item template position, and it appears in the sidebar at the bottom.... but is there a different location I can specify to get it higher on the page and more visible?


    Screenshot at Mar 21 09-49-07.png
  2. Bob

    Bob Developer Staff Member

    You can edit the template and place the code exactly where you want it to display OR the best way IMO is to use a Template Modification.

    Put your site into DEBUG mode so that you can create/edit TMs.

    Create a TM like this:


    Here is what the Test Modification looks like. You can see that the TM found the template syntax you placed in the FIND and inserted the replacement ABOVE it (because the $0 was at the end). If you put $0 at the top of the Replace Block, it will insert it BELOW it.


    Here is the exact text for the FIND:
    <xen:if is="{$item.canViewComments} && {$category.allow_comments}">
    If you don't want to do all the TM stuff, You can simply edit the template and add your code right about the comments section. Adding code to that area will merge with a breeze.
    kontrabass likes this.
  3. kontrabass

    kontrabass Member AMS Premium CAS Premium RMS Premium SC Premium

    Wow thanks Bob! The TM works beautifully. Can't get enough of your awesomeness. :D:D:D:D
    Bob likes this.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.