Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 Design and Graphics Discussions
  #1  
Old 06-14-2012, 02:56 PM
AshenTemper's Avatar
AshenTemper AshenTemper is offline
 
Join Date: Mar 2006
Location: Austin, Texas
Posts: 23
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default How do you set the background color for an input box in focus? [Search]

Here is the image showing the issue:



You can see which box is in focus (it is the one in white). I adjusted the color of these using the following in additional.css:

Code:
.textbox, textarea, select {
    background-color: #1A1A1A;
    border: 1px solid #5B5B5B;
    color: #CCCCCC;
}
Which works great except for when the box is in focus (ie, active and the mouse is in it ready for input data). I've tried a variety of things such as:

Code:
input:focus { background: pink; }
.textbox:focus { background: pink; }
.textarea:focus { background: pink; }
.select:focus { background: pink; }
But none of them have worked. Any idea on how I can change this to be a different color when in focus?
Attached Images
File Type: jpg vbulletin_search_boxhighlight.jpg (38.1 KB, 0 views)
Reply With Quote
  #2  
Old 06-16-2012, 08:54 AM
cellarius's Avatar
cellarius cellarius is offline
 
Join Date: Aug 2005
Posts: 1,987
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Code:
.formcontrols .blockrow input.textbox:focus {
    background: red;
}
Use firebug to find out what css definition is needed.
Reply With Quote
  #3  
Old 06-16-2012, 02:14 PM
AshenTemper's Avatar
AshenTemper AshenTemper is offline
 
Join Date: Mar 2006
Location: Austin, Texas
Posts: 23
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by cellarius View Post
Code:
.formcontrols .blockrow input.textbox:focus {
    background: red;
}
Use firebug to find out what css definition is needed.
Ahh, I am using Chrome's Web Tools which is pretty close to the same but, for the life of me, I just couldn't figure that out. Thanks, I owe you one (it works perfectly).
Reply With Quote
  #4  
Old 06-16-2012, 04:37 PM
cellarius's Avatar
cellarius cellarius is offline
 
Join Date: Aug 2005
Posts: 1,987
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by AshenTemper View Post
Ahh, I am using Chrome's Web Tools which is pretty close to the same
I'm using Chrome for browsing, but for stuff like that I never miss to fire up my firefox just for the full version of firebug. It may be that I'm better used to it, but I never found Chrome's Web Tools came close enough.

Quote:
Thanks, I owe you one (it works perfectly).
Nah, not for that. But if you insist and I ever get around to Texas...
Reply With Quote
Благодарность от:
AshenTemper
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 05:48 AM.


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.03510 seconds
  • Memory Usage 2,214KB
  • Queries Executed 14 (?)
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
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (4)post_thanks_box
  • (1)post_thanks_box_bit
  • (4)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit
  • (4)post_thanks_postbit_info
  • (4)postbit
  • (1)postbit_attachment
  • (4)postbit_onlinestatus
  • (4)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
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • 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
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete