[Support request] About Buttons

Home Forums Support [Support request] About Buttons

Home Forums Support About Buttons

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #2277662
    uglyc

    Dear GP team,

    I use the .button class to create buttons in my post. Here’s what the code looks like:
    Button to Google

    But I have a problem, when I insert a button in my post, it sits at the left side. How can I place it at the middle of the page?
    https://snipboard.io/ugdJ6l.jpg

    #2278084
    Leo
    Staff
    Customer Support

    Hi there,

    Any chance you can link us to the page in question?

    You can use the private information field:
    https://docs.generatepress.com/article/using-the-premium-support-forum/#private-information

    Let me know 🙂

    #2278211
    uglyc

    Hi Leo,

    Thanks for your time. I appreciate your help. Pls see below.
    Plus, pls let me know if I haven’t made myself clear.

    #2278395
    David
    Staff
    Customer Support

    Hi there,

    if you inspect your HTML ( in the code editor ) you will see your <a> is in a <p> like so:

    <p>
        <a class="button sun-flower" rel="nofollow sponsored" href="the_link_url">Check It Out</a>
    </p>

    Edit that code and give the <p> a class of: has-text-align-center

    So it looks like this:

    <p class="has-text-align-center">
        <a class="button sun-flower" rel="nofollow sponsored" href="the_link_url">Check It Out</a>
    </p>
    #2278435
    uglyc

    Hi David,

    Thanks very much for your time. Can I insert the following code directly into the [/]shortcode block? Is it the right way to get the button I want?

    <p class="has-text-align-center">
        <a class="button sun-flower" rel="nofollow sponsored" href="the_link_url">Check It Out</a>
    </p>
    #2278440
    David
    Staff
    Customer Support

    No.
    Options:

    1. Use a HTML block.

    or

    2. From the 3 dot menu in the tool bar, switch to code view. And add the HTML there or just edit the HTML you already have on that page.

    #2278451
    uglyc

    Hi David,

    It works now. Thanks so much a lot.

    #2279126
    David
    Staff
    Customer Support

    You’re welcome

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