[Support request] Affiliate Link Header

Home Forums Support [Support request] Affiliate Link Header

Home Forums Support Affiliate Link Header

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #2523655
    Arun

    Hey There, I want to add header for “This post may contain affiliate links. Read out our full disclosure for more info. I tried many of the support forum things but it did’nt work out. can you give me just code so i can put under Hook> Code> and display rule. I also want a different background for that just like this website https://www.dollarfinancials.com/legit-cash-games/ and here are the screenshot of the website. Screenshot of Header

    #2523663
    Leo
    Staff
    Customer Support

    Hi there,

    Are you using the block editor?

    Let me know 🙂

    #2523669
    Arun

    No i’m not using block editor and i’m not expert with css or any other language. can you just give me the code as the above website (which one i mentioned) so it will be easy for me to do so.

    #2523871
    Leo
    Staff
    Customer Support

    No i’m not using block editor and i’m not expert with css or any other language.

    In that case, I would highly recommend the using the block editor – it’s designed for users without any coding knowledge.

    The example you’ve shown is using the block editor as well without any coding.

    can you just give me the code as the above website (which one i mentioned) so it will be easy for me to do so.

    We normally cannot provide a full HTML and CSS solution as it’s not a theme-related request and can be achieved easily with the block editor. However, this one is simple enough I can make an exception.

    Here is the HTML content:
    <div class="affiliate-message"><em>This post may contain affiliate links. Please read our <a href="https://URL here" target="_blank">disclosure</a> for more info.</em></div>

    And here is the CSS:

    .affiliate-message {
        padding: 20px;
        background-color: #2222;
    }

    Adding CSS: https://docs.generatepress.com/article/adding-css/

    Choose the hook generate_after_entry_title and set the priority to 11.

    The display rules would be Posts > All posts.

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