Home › Forums › JavaScript › show div when the very bottom on the website is reached
- This topic is empty.
-
AuthorPosts
-
July 26, 2013 at 12:02 pm #144737
Anonymous
InactiveI have print button and i want it to show when the user reaches the very bottom of the website. it will have display:none with css and maybe using jquery display:visible but when the user reaches the bottom. http://reallycoolstuff.net/PROJECTS/jobmagnet/
July 26, 2013 at 1:06 pm #144743Kuzyo
ParticipantMaybe, you find usefull http://codepen.io/Kuzyo/pen/pcIhx
July 26, 2013 at 1:09 pm #144744Anonymous
InactiveSomething like that is what i am looking for. But i also want the button to hide when the user scrolls up.
July 26, 2013 at 1:29 pm #144746Kuzyo
ParticipantUpdated: http://codepen.io/Kuzyo/pen/pcIhx
July 26, 2013 at 2:41 pm #144754Anonymous
Inactivei want it to fade in when the bottom of the site is reached, and fade out when the user scrolls out of the bottom. as soon as they start scrolling up from the bottom. That doesnt do it.
July 26, 2013 at 2:54 pm #144755Kuzyo
ParticipantI thought, it will help
July 26, 2013 at 3:03 pm #144757Anonymous
Inactive@Juzyo and it did thank you for your help. But i want something slightly different.
July 26, 2013 at 3:51 pm #144758Alen
ParticipantSomething like this:
July 26, 2013 at 4:26 pm #144763Anonymous
Inactive@Alen Looks like its working but the opposite way. Any idea why? http://reallycoolstuff.net/PROJECTS/jobmagnet/
July 26, 2013 at 6:32 pm #144768Alen
ParticipantDid you hide the button first. As you can see in the code I provided first line hides the button then, when page reaches bottom, button fades in.
Try that, see if it works
July 26, 2013 at 6:59 pm #144769Anonymous
InactiveYes i did and its the same. I removed it because i hide the buttons with css instead of jquery. Anyway i added the hide() in the jquery and its still not working.
July 26, 2013 at 10:44 pm #144780Kuzyo
Participant@Jarolin It seems that $(window).scrollTop() don’t add to $(window).height() maybe try additionall parentheses this way:
if( ( $(window).scrollTop() + $(window).height() ) == $(document).height())
July 27, 2013 at 7:14 am #144830Anonymous
Inactive@crocoDillon Yours is also working but the opposit way too, This is totally weird. And i would preffer to hide the buttons because they are still clickable when hidden. Also when you scroll with the scroll bar and hold it the buttons only dissapear once you let go.
July 27, 2013 at 5:42 pm #144859Alen
Participant@CrocoDillon i like your solution better.
July 29, 2013 at 1:40 am #144943meisp123
ParticipantLocated in Zhengzhou, “Henan” where a team soccer jerseys for cheap
in the province, not a city. They are still using last season’s jersey, NIKE, which give them a decent design, red and green with a bit of fun. There may be no new Jersey, but probably just a mass of templates in conjunction with a blue NIKE -
AuthorPosts
- The forum ‘JavaScript’ is closed to new topics and replies.