• Resolved nevrsmer

    (@nevrsmer)


    Hello,

    Can I use this plugin to run Pinterest’s “Pin It” code on certain posts instead globally? The way we have it now, Pin It appears on all images on all pages and posts on our site. We only want it to appear on the images on certain posts. Also, these pages are created in Guttenberg and do have some Elementor script for some styling.

    This is the script in question: “<script async defer data-pin-hover=”true” src=”//assets.pinterest.com/js/pinit.js”></script>”

    Thank you for your help and have a good day.

    Cheers!

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hello.

    The plugin has additional logic for displaying snippets. It works for all types of snippets except the PHP snippet.

    View post on imgur.com

    Giang Le

    (@gianghl1983)

    @webtemyk Hi, I have the same question, just want snippets to be used in certain page (by ID/Slug/Name of that pages…).

    I try Current Page condition without success (using ID, slug, page name…)

    Do you have any guidance for this?

    Thanks!

    Temyk

    (@webtemyk)

    Hi, @gianghl1983

    Each item has a tooltip. https://imgur.com/fZXLj4k
    Current Page checks the URL of the page where the user is currently located. This is why you need to enter the URL. If you want to use for example a post slug, select Contains

    Giang Le

    (@gianghl1983)

    @webtemyk Thank you! It worked flawlessly.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Run Javascript on Certain Posts’ is closed to new replies.