Okay
  Public Ticket #3720893
Use "back to top" on a single page
Closed

Comments

  •  17
    JPDStudio started the conversation

    Hi Salient team!

    I turned off the option to have the "back to top" link on every page but I now need to place it on just one page. Is it possible to add code to a specific page to restore the "back to top" link? We'd like it to be sticky.

    I wanted to make sure to ask you first before I consider adding a plugin as we'd prefer to make use of the theme's functionality.

    Thank you!
    Jes

  •  8,837
    Tahir replied

    Hey Again,

    You can enable it for all pages and then use CSS to only show on the particular page. Let us know the page url so we can write up the correct CSS for it. 

    Thanks.


    ThemeNectar Support Team 

  •  2,958
    Andrew replied

    Hi Jessica,

    Thank you for reaching out to us.

    You can enable the button then share the URL for where you want the button to appear and we can share CSS that will remove the button from all pages except that one.

    We look forward to your reply.

    Thanks,

  •   JPDStudio replied privately
  •  2,958
    Andrew replied

    Hi Jes,

    Thank you for getting back to us.

    Please ensure that you have activated the back to top button in the Salient settings so we can add CSS to hide it on other pages other thank this one.

    We look forward to your reply.

    Thanks,

  •  17
    JPDStudio replied

    I just activated the button. Thank you!

  •  1,875
    Judith replied

    Hi there,

    Thanks for writing back.

    Please confirm whether this is now resolved for you.

    I look forward to your response.

  •  17
    JPDStudio replied

    Hi Judith,

    I believe Andrew was going to provide css that I could add to the site to hide it on all pages except the one page. I haven't received it, also I emptied the cache and am still seeing the back to top arrow on all pages.

    Best,
    Jes

  •  1,875
    Judith replied

    Hi there,

    Thanks for writing back.

    To make the changes as requested, you will need to add some custom CSS code. To do this, please follow these steps:

    From your WordPress dashboard, Navigate to Salient > General Settings > CSS/Script Related. In the custom code area, insert the provided CSS snippet:

    #to-top {
        display: none;
    }
    .page-id-14122 #to-top {
        display: block !important;
    }

    Once the code is added, save and refresh the page to see if the change has been applied. In case it helps, please check this section from the documentation on CSS/Script Related.

     If this does not work as expected or If you have any further questions or need additional assistance, don't hesitate to write back, I'm happy to help. 


  •  8,837
    Tahir replied

    Hey Again,

    Add this into the Custom CSS box in your Salient Theme Options panel (We write all Custom CSS in the Live Browser to ensure accuracy. If you cannot see any changes, make sure there is no red cross in the Custom CSS Box as any syntax error would cause all CSS under that line of code to not show up on the Frontend):

    body:not(.page-id-14122) #to-top{
        display:none !important;
    }

    Thanks


    ThemeNectar Support Team