Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 08-19-2006, 10:19 PM
johnstires johnstires is offline
 
Join Date: Mar 2006
Posts: 195
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Changing the navbar background color

How does one change the navbar background color without changing the other popup menus?

I tried to create a custom style named .navbar_bgcolor and replaced all the vbmenu_control tags in the navbar template with navbar_bgcolor, but it did not work.

I think my CSS was off

This is what I put in my custom style:

Quote:
.navbar_color { font-color: #FFFFFF;
background-color:#4C1A79;
}
The color changes but not the font color. However the font defaulting to the body style color.
Reply With Quote
  #2  
Old 08-20-2006, 05:58 AM
Ntfu2 Ntfu2 is offline
 
Join Date: Feb 2006
Posts: 1,247
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

you dont want to use font-color as the links arent controled by the font attribute

try something like this

Code:
.navbar_color a:link, a:visited {font-size: 12px; color: #FFFFFF; text-decoration: underline;}
.navbar_color a:hover,  a:active {color: #E1E1E2; text-decoration: underline;}
Reply With Quote
  #3  
Old 08-21-2006, 02:18 AM
johnstires johnstires is offline
 
Join Date: Mar 2006
Posts: 195
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

This works, however it is wreaking havoc on other links on the board in IE. Why would a custom class be changing the style in other templates when the only template I have been fiddling with is the navbar.
Reply With Quote
  #4  
Old 08-22-2006, 04:47 PM
johnstires johnstires is offline
 
Join Date: Mar 2006
Posts: 195
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How can I hard code this to change the background. Everything else can stay the same. I just want to bg color to be:#4C1A79.

I can change the <td> but not the <table> or the <tr>

This is the start of the code, shouldn't I be able to place style="background: #4C1A79" somewhere in there for the entire navbar to be made dark purple?

Code:
<div align="center">
	<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="0" border="0" width="100%" align="center" style="border-top-width:0px">


<td id="newlink" class="vbmenu_control"><a href="usercp.php$session[sessionurl_q]">PYC Home</a> <script type="text/javascript"> vbmenu_register("newlink"); </script></td>
Reply With Quote
  #5  
Old 08-22-2006, 06:18 PM
Ntfu2 Ntfu2 is offline
 
Join Date: Feb 2006
Posts: 1,247
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

try placing the code you mentioned within the <div align="center" tag

Code:
<div align="center" style="background:.......>
Maybe that'll work
Reply With Quote
  #6  
Old 08-23-2006, 01:34 AM
johnstires johnstires is offline
 
Join Date: Mar 2006
Posts: 195
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I tried that before and it didn't work.

THe guys at vb.com helped me figure it out. I placed this in my additional CSS:

Code:
/* ***** navbar back color ***** */

.navbar_color
{
	background: #4C1A79;
	color: #FFFFFF;
	font: bold 11px tahoma, verdana, geneva, lucida, 'lucida grande', arial, helvetica, sans-serif;
	padding: 3px 6px 3px 6px;
	white-space: nowrap;
}
.navbar_color a:link, .navbar_color_alink
{
	color: #FFFFFF;
	text-decoration: none;
text-transform: uppercase;
}
.navbar_color a:visited, .navbar_color_avisited
{
	color: #FFFFFF;
	text-decoration: none;
text-transform: uppercase;
}
.navbar_color a:hover, .navbar_color a:active, .navbar_color_ahover
{
	color: #FFFFFF;
	text-decoration: underline;
text-transform: uppercase;
}
Then I changed all the vbmenu_control tags in the navbar to navbar_color.

That worked.
Reply With Quote
Reply


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 02:08 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.04070 seconds
  • Memory Usage 2,210KB
  • Queries Executed 13 (?)
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
  • (4)bbcode_code
  • (1)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_postinfo_query
  • fetch_postinfo
  • 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