The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
Awesome Sticky Top Bar by XiTCLUB Details »» | |||||||||||||||||||||||||
==================
AWESOME STICKY TOP BAR ================== LIVE DEMO : WWW.XiTCLUB.COM INSTALLATION 1: Goto Admincp > Styles & Templates > Style manager > Your Theme > Edit "header" template Add The Following Code at the End Code:
<div id="stickyBar"> <ul> <li><a href="#">Link1 </a></li> <li><a href="#">Link 2 </a></li> <li><a href="#">Link 3 </a></li> <li><a href="#">Link 4 </a></li> <li><a href="#">Link 5 </a></li> </ul> </div> 2: Goto Admincp > Styles & Templates > Style manager > Your Theme > Edit "additional.css" template Add The Following Code at the End Code:
#stickyBar { background: rgba(0,0,0, 0.8); border-radius: 0 0 0.5em 0.5em; display:none; height:40px; } #stickyBar ul { margin:0px; padding: 0; list-style:none; } #stickyBar ul li { float:left; min-width:80px; text-align:center; border-right:1px solid #ccc; font-size: 16px; height: 40px; line-height: 2.5em; padding:0 5px; } #stickyBar ul li a { color:#fff; display: block; width:100%; height:100%; } #stickyBar ul li a:hover { background: red; color:#fff; } #stickyBar.stick { position: fixed; top: 0; z-index: 10000; width:1000px; margin:0 auto; background: rgba(0,0,0, 0.8); border-radius: 0 0 0.5em 0.5em; display: block; } Add The Following Code at the End Code:
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.0/jquery.min.js"></script> <script> function sticky_relocate() { var window_top = $(window).scrollTop(); var div_top = $('.above_body').offset().top; if (window_top > div_top) { $('#stickyBar').addClass('stick'); } else { $('#stickyBar').removeClass('stick'); } } $(function() { $(window).scroll(sticky_relocate); sticky_relocate(); }); </script> That's it... Enjoy Sticky Top Navigation By XiTCLUB Update : Updated The Whole Tutorial, because most of peoples are not familiar with programing You can Buy me a bear if you like this modification, paypal button is at right sidebar Show Your Support
|
3 благодарности(ей) от: | ||
evelynpriscilla, JamalFree, thang28101993 |
Comments |
#22
|
|||
|
|||
Thanks for your help!!!!!!!!
Finally I can manage with it without knowing so much of css and html. Recommended!!!!!! |
#23
|
|||
|
|||
Congratulations :P
|
#24
|
|||
|
|||
Cool! Nice work.
Is this one mod (see screenshot) available/supported? |
#25
|
|||
|
|||
No, This mod is not available yet
|
#26
|
|||
|
|||
Shahzad saab you have a cool forum best of luck i am paki too
|
#27
|
|||
|
|||
Thank You Bhai Sahb..
|
#28
|
|||
|
|||
Thanks for mod!
However, I have to mention that this script is not compatible with any query version except jquery.min.js so for those who the code didn't for them, I guess it is compatibility issue. Being said that, we have to add extra script to the header while there are many others already there. I believe it is better to take the advantage of the other used jquery versions that are already in used at vb header.... I know if you decided to change the whole code, it may take some time to re-create the java script that is compatible with all jquery versions.... or at least the one used at vb header... Thanks |
#29
|
|||
|
|||
Quote:
|
#30
|
|||
|
|||
Quote:
you can try it out and see yourself if it functions with other jquery versions if you like ... |
#31
|
|||
|
|||
It was not working in my IE and if anyone has the same problem, here is how i fixed it:
I replaced: HTML Code:
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.0/jquery.min.js"></script> HTML Code:
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js">
Also, i've added a solid background-color to #stickyBar, a line before the background: rgba(0,0,0, 0.8); @XiTCLUB Is there anyway to get the bar displayed after the page scrolls a certain number of px from the top? By the way, awesome indeed! |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|