Go Back   vb.org Archive > vBulletin Modifications > vBulletin 4.x Modifications > vBulletin 4.x Template Modifications

Reply
 
Thread Tools
Awesome Sticky Top Bar by XiTCLUB Details »»
Awesome Sticky Top Bar by XiTCLUB
Version: 1.00, by XiTCLUB XiTCLUB is offline
Developer Last Online: Feb 2020 Show Printable Version Email this Page

Category: Forum Display Enhancements - Version: 4.x.x Rating:
Released: 04-23-2013 Last Update: Never Installs: 21
Template Edits
Re-useable Code Translations  
No support by the author.

==================
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;
}
3: Goto Admincp > Styles & Templates > Style manager > Your Theme > Edit "headinclude" template

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

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
3 благодарности(ей) от:
evelynpriscilla, JamalFree, thang28101993

Comments
  #12  
Old 04-24-2013, 12:39 PM
thang28101993 thang28101993 is offline
 
Join Date: Feb 2010
Location: fdsaf
Posts: 50
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for your support!
I tried, but Can't do it for my forum as yours! Please check again and tell us the way clearly, how can do!

Thanks!
Reply With Quote
  #13  
Old 04-24-2013, 12:48 PM
XiTCLUB XiTCLUB is offline
 
Join Date: Jan 2010
Location: Lahore, Pakistan
Posts: 304
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by thang28101993 View Post
Thanks for your support!
I tried, but Can't do it for my forum as yours! Please check again and tell us the way clearly, how can do!

Thanks!
I have showed the way how you can stick a bar at top. but bar style is not my concern, everyone can style their bar
Reply With Quote
  #14  
Old 04-24-2013, 02:46 PM
inigo inigo is offline
 
Join Date: May 2010
Location: Spain
Posts: 102
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by XiTCLUB View Post
Your forum link ?
I have it in local, not live.

I will continue subscribed to this post to see if it is any solution,

Thanks!

EDIT: How can I check the jquery version the system is loading? and where can I change it?
I have this in HEDINCLUDE template:
PHP Code:
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.0/jquery.min.js"></script


Perhaps the problem is that I have the Tab menu mod installed,...:
https://vborg.vbsupport.ru/showthrea...highlight=tabs

I have to check more in detail where is the problem.
Reply With Quote
  #15  
Old 04-24-2013, 05:09 PM
XiTCLUB XiTCLUB is offline
 
Join Date: Jan 2010
Location: Lahore, Pakistan
Posts: 304
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by inigo View Post
I have it in local, not live.

I will continue subscribed to this post to see if it is any solution,

Thanks!

EDIT: How can I check the jquery version the system is loading? and where can I change it?
I have this in HEDINCLUDE template:
PHP Code:
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.0/jquery.min.js"></script


Perhaps the problem is that I have the Tab menu mod installed,...:
https://vborg.vbsupport.ru/showthrea...highlight=tabs

I have to check more in detail where is the problem.
Updated The Tutorial
Reply With Quote
  #16  
Old 04-24-2013, 11:00 PM
Bluefin221 Bluefin221 is offline
 
Join Date: Jul 2008
Location: Scotland
Posts: 290
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Works better as an iframe this.
Reply With Quote
  #17  
Old 04-25-2013, 06:17 AM
inigo inigo is offline
 
Join Date: May 2010
Location: Spain
Posts: 102
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

XiTClub, thanks very much for the tutorial, I have finally it working changing #navigation to #navtabs in your previous tutorial.

The only problem is the floatcontainer below the navtabs, is showed only the text without background color,... I am trying to improve this

This new tutorial is good too, but the previous one is perfect when optimized.

I suggest both tutorial in 1st post,m because depending of the user, one of them could be slightly better

Thanks a lot, mark as installed and 4 stars at the moment, but if i can finish with the floatcontainer below the navbar 5 stars,
Reply With Quote
  #18  
Old 04-25-2013, 07:59 AM
XiTCLUB XiTCLUB is offline
 
Join Date: Jan 2010
Location: Lahore, Pakistan
Posts: 304
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by inigo View Post
XiTClub, thanks very much for the tutorial, I have finally it working changing #navigation to #navtabs in your previous tutorial.

The only problem is the floatcontainer below the navtabs, is showed only the text without background color,... I am trying to improve this

This new tutorial is good too, but the previous one is perfect when optimized.

I suggest both tutorial in 1st post,m because depending of the user, one of them could be slightly better

Thanks a lot, mark as installed and 4 stars at the moment, but if i can finish with the floatcontainer below the navbar 5 stars,
Good to know

1st tutorial was for professionals and when i came to know that everyone here complaining its not working because of their own lack of knowledge bout HTML, CSS, jQuery. so i have decided to make it simpler :P
Reply With Quote
  #19  
Old 04-25-2013, 10:19 AM
faisaly.com faisaly.com is offline
 
Join Date: Mar 2007
Posts: 226
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Heres a screenshot:

Reply With Quote
  #20  
Old 04-25-2013, 10:23 AM
XiTCLUB XiTCLUB is offline
 
Join Date: Jan 2010
Location: Lahore, Pakistan
Posts: 304
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by faisaly.com View Post
Heres a screenshot:

looks like you installed 100% :P
Reply With Quote
  #21  
Old 04-25-2013, 10:46 AM
faisaly.com faisaly.com is offline
 
Join Date: Mar 2007
Posts: 226
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

grabbed from demo
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 10:37 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05826 seconds
  • Memory Usage 2,335KB
  • Queries Executed 26 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (3)bbcode_code
  • (2)bbcode_php
  • (5)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (3)post_thanks_box_bit
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete