Jump to content

Recommended Posts

Hi,

 

I want to style an input field and leave the submit button alone.

 

#header_search input {
width: 150px;
background: url(layout/input_bg.png) repeat-x;
border: 1px solid #6d6d6d;
}
#header_search input:hover {
border: 1px solid #205bc0;
}

 

The problem is that this code affects all input including textfields and submit buttons! How can I tag only textfields using css?

Link to comment
https://forums.phpfreaks.com/topic/87479-input-field/
Share on other sites

 

you can just give each of your textfields the same class and style as needed. using "input" will cover all input types; it's not just limited to textfields. you also could just leave your submit button outside the html element; the one that you have given the id of "header_search" to.

Link to comment
https://forums.phpfreaks.com/topic/87479-input-field/#findComment-447439
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.