Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 General Discussions
  #1  
Old 12-18-2010, 09:35 PM
AlexisMedia AlexisMedia is offline
 
Join Date: Dec 2010
Posts: 96
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default How to Change Nav Bar Tab Hover Color

It appears the admin stylevar uses navbar_tab_selected_background as both the selected and the hover color. How can I get a different hover color then selected? I'm referring to the "forum" and "what's new" tabs...

Thanks!
Reply With Quote
  #2  
Old 12-18-2010, 10:01 PM
TheLastSuperman's Avatar
TheLastSuperman TheLastSuperman is offline
Senior Member
 
Join Date: Sep 2008
Location: North Carolina
Posts: 5,844
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by AlexisMedia View Post
It appears the admin stylevar uses navbar_tab_selected_background as both the selected and the hover color. How can I get a different hover color then selected? I'm referring to the "forum" and "what's new" tabs...

Thanks!
Edit the CSS Template: vbulletin-chrome.css

Find:

Code:
.navtabs li.selected a.navtab {
	color:{vb:stylevar navbar_tab_linkhover_color};
	background:{vb:stylevar navbar_tab_selected_background};
        _background-image:none;
	position:relative;
	top:-{vb:stylevar navbar_tab_selected_top_width}px;
	padding-top:{vb:stylevar navbar_tab_selected_top_width}px;
	z-index:10;
}
Replace {vb:stylevar navbar_tab_linkhover_color} with either a hex #FF0000 or a rgb(205, 205, 205) value OR use another stylevar you know has the correct color .
Reply With Quote
  #3  
Old 12-19-2010, 05:11 PM
LifesGreatestGift's Avatar
LifesGreatestGift LifesGreatestGift is offline
 
Join Date: Jul 2009
Location: Louisville, KY USA
Posts: 885
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

you will need to add some new css code

You can change the "selected" color in the stylevar. For hover color go to template additional.css

Add the following, feel free to customize the color

Code:
.navtabs li a.navtab:hover {
	color:#ffffff; /* Color of text for hover */
	background-color:#000000; /* Color for background of button when hovered */
}
Now if you'd like to use an image for the background button hover then use

background:url(hxxp://urltoimage.png) #000000 no-repeat;

as opposed to background-color
Reply With Quote
  #4  
Old 12-20-2010, 09:53 PM
AlexisMedia AlexisMedia is offline
 
Join Date: Dec 2010
Posts: 96
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by TheLastSuperman View Post
Edit the CSS Template: vbulletin-chrome.css
Can I ask how you knew that would be located in that specific template? I never would have guessed that as it's not named anywhere close? I'd like to be able to hunt this stuff down on my own quickly if I can learn it : )

Thanks!

--------------- Added [DATE]1292889310[/DATE] at [TIME]1292889310[/TIME] ---------------

Quote:
Originally Posted by TheWindows7Site View Post
go to template additional.css
I've already done it the other way but this way is a good idea to change it too so I have less edit logging to do then it sounds like...

Thanks!
Reply With Quote
  #5  
Old 12-20-2010, 10:31 PM
LifesGreatestGift's Avatar
LifesGreatestGift LifesGreatestGift is offline
 
Join Date: Jul 2009
Location: Louisville, KY USA
Posts: 885
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

He finds the css identifier with firebug then searches in templates to see where it is called. More than likely most styling is called in vbulletin-chrome.css
Reply With Quote
  #6  
Old 12-20-2010, 11:13 PM
AlexisMedia AlexisMedia is offline
 
Join Date: Dec 2010
Posts: 96
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok, got ya... Thanks!
Reply With Quote
Reply

Thread Tools
Display Modes

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 06:00 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04775 seconds
  • Memory Usage 2,207KB
  • Queries Executed 11 (?)
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
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (2)bbcode_code
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (6)post_thanks_box
  • (6)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (6)post_thanks_postbit_info
  • (6)postbit
  • (6)postbit_onlinestatus
  • (6)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
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete