dom - Implementing a simple floating navigation in Javascript -


I am trying to implement a simple floating navigation using DOM and Javascript. The following script is triggered using the oncroll event, but nothing happens through firebug and debugging is not completely enlightened.

  function float_nav () {nav = document.getElementById ("nav_container"); Offset = window Pagewise offset + 'px;'; Nav.style.top = offset; }  

You do not have to add; At the end of px otherwise I do not see anything wrong.

Extra: Why do not you use jQuery or something similar?


Comments

Popular posts from this blog

c# - sqlDecimal to decimal clr stored procedure Unable to cast object of type 'System.Data.SqlTypes.SqlDecimal' to type 'System.IConvertible' -

Calling GetGUIThreadInfo from Outlook VBA -

Obfuscating Python code? -