Saturday, November 17, 2018

CSS Forms

<form action='' method=''>

<input type='text' name='name'/>
<input type='Email' name='Email'/>
<input type='submit' name='submit'/>

</form>

input[type=text] 
{
    width: 100%;
    padding: 12px 20px;
    margin: 8px 0;
    box-sizing: border-box;
}


Note that we have set the box-sizing property to border-box. This makes sure that the padding and eventually borders are included in the total width and height of the elements. 
Read more about the box-sizing property in our CSS Box Sizing chapter.

input[type=text] {
    border: 2px solid red;
    border-radius: 4px;
}

If you only want a bottom border, use the border-bottom property:


























Share:

Related Posts:

0 comments:

Post a Comment

Contact Form

Name

Email *

Message *

Popular Posts

Blog Archive

Blog Archive

Hassan.mosmer1@gmail.com