javascript - floating menu bar in containing div (js) -
I have a JavaScript menu bar located on my webpage, then when the browser reaches the top of the bar menu it The lock runs in a fixed position and with the window However, I have to include the menu within a single divas, how can this be done?
This is my menu bar:
& lt; Script type = "text / javascript" Src = "http://ajax.googleapis.com/ajax/libs/jquery/1.5.1/jquery.min.js" & gt; & Lt; / Script & gt; & Lt; Script type = 'text / javascript' & gt; $ (Window) .load (function () ($) (window) .scroll (function () (if ($ (window) .scrollTop ()> gt = 200) {$ ("# floatbar"). CSS ({status : 'Fixed', left: '0', above: '0'});} and {$ ("# flotbar"). CSS ({status: 'full', left: '0', above: '200px' }}}}}}}};
Comments
Post a Comment