![]() |
|
Back to to button - Printable Version +- Sinisterly (https://sinister.ly) +-- Forum: Design (https://sinister.ly/Forum-Design) +--- Forum: Web Design (https://sinister.ly/Forum-Web-Design) +--- Thread: Back to to button (/Thread-Back-to-to-button) |
Back to to button - BlueCat - 05-20-2014 Been trying to create a nice back to top button for about half an hour now. But where ever I scroll the button follws, I want it to stay at the button. I would it like HC Current code I have for it. Code: #top-link {
display:none;
position: fixed;
botton: 0px;
right: 30px;
top: 150px;
font-weight: bold;
background: black;
}RE: Back to to button - Souvarine - 05-20-2014 Few things here: - you misspelled bottom - if you want your button to be on the bottom of the page you don't need top property in your CSS file Have you checked everything is alright with your script for 'back to top button'? - if you are using jQuery make sure to have it included in page head - also, I suggest you to use existing code for this function, it is safer and easier RE: Back to to button - Inori - 05-22-2014 A good little trick: google element. If you're on chrome, right click the 'back to top' bar, select 'inspect element' and copy the code. What I got: Code: <p id="back-top" class="bounceInUp animated">
<a href="#top">
<span></span>
"Scroll me back to the top !"
</a>
</p>RE: Back to to button - Justice_mybb_import8175 - 05-28-2014 @Jinxed its a link to #top which means that in the CSS file there is a property called #top that scrolls you up to the top of the page. You would have to alter your CSS to make it work. To get anything to stay in a certain spot you need to give it a fixed property, position: absoulute;. Hope that helps you out. |