Site logo

[Support request] Affiliate Activity Widgets not working

Home Forums Support [Support request] Affiliate Activity Widgets not working

Home Forums Support Affiliate Activity Widgets not working

Viewing 15 posts - 1 through 15 (of 18 total)
  • Author
    Posts
  • #1756469
    Jonny

    Hello,

    Since installing the GeneratePress theme on my website, I have noticed the activity widgets that I use from affiliate programs such as Get Your Guide, Viator, Klook, etc. are not displaying in any of my blog posts…

    In the backend of WordPress, I checked the source code of my posts where I have inserted the code for these affiliate activity widgets and the code is still there, but on the front end, they are not displaying.

    Please find a link to one of my blog posts where you’ll see a H2 heading ‘Best Tours In Bali’ and beneath this heading is where the activity widget should be visible.

    Any help would be greatly appreciated as to why these widgets are not displaying anymore.

    #1756622
    Elvin
    Staff
    Customer Support

    Hi there,

    I’m not exactly sure what I’m supposed to see here.
    https://share.getcloudapp.com/xQubEG8j

    Here’s the rendered HTML after h2.
    https://share.getcloudapp.com/X6ue7g1J

    Can you explain a bit more on what I’m supposed to see? Should some sort of layout be visible below the mentioned heading?

    #1756630
    Jonny

    Hey Elvin,

    Please see this screenshot – https://drive.google.com/file/d/1KncmbxebWajHoTh-Udhoqxpa2KUgViv1/view?usp=sharing

    This is an activity widget that I use in the majority of my blog posts to promote tours from websites such as Klook, Get Your Guide, etc.

    Since installing GeneratePress, all of these activity widgets have disappeared…

    #1756758
    Elvin
    Staff
    Customer Support

    How are you adding the code for that? Is it on a functions.php?

    Any chance you can provide is temporary back-end access to check?

    #1756782
    Jonny

    Hi Elvin,

    I have been pasting in the HTML code for the activity widget using the text editor in WordPress posts.

    #1756819
    Elvin
    Staff
    Customer Support

    I have been pasting in the HTML code for the activity widget using the text editor in WordPress posts.

    Are you editing the page content using Block editor? If yes, can you try using the custom HTML block?

    If it doesn’t work, can you share w/ us the exact code you’re using? Let us know.

    #1756859
    Jonny

    No, I edit all my posts with the Classic Editor.

    Yes, here’s the code which I copy and paste from the affiliate partner Viator.

     

    <script src=”https://www.viator.com/orion/partner/widget.js&#8221; async=””></script>

    #1756893
    Elvin
    Staff
    Customer Support

    That’s only the script. I believe that should come w/ some div tags.

    It looks like some parts of the code are missing.

    I didn’t a quick investigation and it seems like it does.

    https://agentcenter.viator.com/resources/widget/

    You should include the missing parts as well.

    #1756900
    Jonny

    Hi Elvin,

    For some reason, the whole code wouldn’t paste and send in this chat. Please see the screenshot attached in the private info box to see the code I have used.

    #1756964
    Elvin
    Staff
    Customer Support

    Try this checking this.

    If I remember it right, the classic editor had 2 parts. One is visual and there other is the text(the one with the HTML tags).

    Can you re-paste your HTML code on the text tab/mode? your script tags are being wrapped in <p> tags

    Also, have you tried checking the sample post w/ all plugins disabled except GP Premium? To check for any plugin conflicts.

    #1762799
    Jonny

    Hello,

    Yes, correct. I have pasted the HTML code in the text tab/mode and still, the widget is not displaying in the post on the front end. I also don’t see the script wrapped in <p> tags…

    There are no plug-in conflicts.

    #1762877
    Elvin
    Staff
    Customer Support

    It’s quite hard to figure this out when we don’t know what’s supposed to show up.

    Plus, there are third-party addons with scripts that we don’t completely know off as this isn’t exactly a theme issue. It’s somewhat out of our scope of support.

    But to help you out.

    I’ve gone the extra mile and copied your code to test on my site and when I removed all the extra attributes and DOMs added by the plugins on your site like EZ TOC, and pasted simply the code and the script, it worked.

    See the demo page here:
    Demo for jonnymelon

    I’m using HTML block on Block editor. It’s possible a classic editor issue or a classic editor + another plugin issue.

    #1762897
    Jonny

    Very much appreciate you taking the time to test this code on your site.

    When you say you removed extra attributes and DOMs created my Easy Table Of Contents, how exactly did you do this? Is it something I can do in the classic editor without having to deactivate the Table Of Contents plugin?

    If this is out of your scope no worries, I thought I’d ask. 🙂

    #1762905
    Elvin
    Staff
    Customer Support

    When you say you removed extra attributes and DOMs created my Easy Table Of Contents, how exactly did you do this? Is it something I can do in the classic editor without having to deactivate the Table Of Contents plugin?

    I’m not sure if EZ TOC is relevant or if what I’ve stripped even matters as it only deals with the <h2> tag so perhaps you can ignore that.

    Here’s the exact code I’ve used:

    <h2 style="text-align: center;">
    <strong>BEST TOURS IN BALI</strong>
    </h2>
    
    <div data-vi-partner-id="P00039717" data-vi-language="en" data-vi-currency="USD" data-vi-partner-type="AFFILIATE" data-vi-url="https://www.viator.com/Bali/d98-ttd?sortType=featured" data-vi-total-products="3" data-slot-rendered-dynamic="true" data-wpmeteor-mouseover="true" data-wpmeteor-mouseout="true">&nbsp;</div>
    
    <script src="https://www.viator.com/orion/partner/widget.js" async=""></script>

    I basically just copied your code and corrected a few syntax errors. You can try this yourself as well and see if it works.

    #1762913
    Jonny

    Ok yes, that code works on my end now.

    However, it seems to have dragged the TOC with it, if that makes sense?

    I placed the activity widget lower down in my blog post and the TOC is meant to be positioned above the first H2 heading within the blog post.

    Here’s a screenshot – https://drive.google.com/file/d/1RTsbLjAmN9JlY3TnG8X3Khcry6Xmjwp4/view?usp=sharing

    Perhaps it is the TOC plugin that is causing issues…

Viewing 15 posts - 1 through 15 (of 18 total)
  • You must be logged in to reply to this topic.