javascript - jQuery scrolltop firefox not working -


this script:

function onscroll(){     document.getelementbyid("divs").style.top=""+$('body').scrolltop()+"px"; } 

fiddle: http://jsfiddle.net/hed2j/1/

doesn't work on latest firefox version!

what doing wrong? :) help!

edit: edited jsfiddle , full script :) attached onscroll event

try fiddle, working in chrome, ie , latest version of mozilla : http://jsfiddle.net/hed2j/3/

i replace $('body').scrolltop() $(window).scrolltop().


Comments

Popular posts from this blog

html5 - What is breaking my page when printing? -

html - Unable to style the color of bullets in a list -

c# - must be a non-abstract type with a public parameterless constructor in redis -