Envelope Template HTML5 and CSS3 contact

View: 606    Dowload: 0   Comment: 0   Post by: admin   Category: HTML-CSS template   Fields: Other

File has been tested

To attract visitors to your Blog or web, you need a cool sample contact form to keep in touch with the user. In this article, I will share with you a sample contact form is designed as an envelope, you will not be able to use this template for your site, but you will learn a lot more from CSS3 properties as well as the HTML5 element in the design of the form.

HTML

We just need to build simple html standard framework as follows:

<div id="form-wrapper">
    <form>
        <div id="form-inner">
 
            <label for="name">Name:</label>
            <input type="text" class="input" id="name" placeholder="John Doe">
 
            <label for="email">Email:</label>
            <input type="email" class="input" id="email" placeholder="john.doe@email.com">
 
            <label for="message">Message:</label>
            <textarea class="input textarea" id="message" placeholder="Your message here"></textarea>    
 
             <input type="submit" class="button" value="Send message">
 
        </div>
    </form>
</div>

CSS

We will use the attributes CSS3 box shadows and gradients to create the effect of packaging message with the following code:

#form-wrapper {
    width: 700px;
    height: 400px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
    border: 1px solid #ddd;
    background-color: #fff;
    background-image: repeating-linear-gradient
                        (135deg,#844049,#844049,
                        #fff 50px, #fff 150px,
                        #3e4996 100px, #3e4996,
                        #fff 200px, #fff 300px);
}
 
#form-wrapper:before, #form-wrapper:after {
    z-index: -1;
    position: absolute;
    content: "";
    bottom: 15px;
    left: 10px;
    width: 50%;
    top: 80%;
    max-width:300px;
    background: rgba(0, 0, 0, 0.7);
    box-shadow: 0 15px 10px rgba(0, 0, 0, 0.7);
    transform: rotate(-3deg);
}
 
#form-wrapper:after {
    transform: rotate(3deg);
    right: 10px;
    left: auto;
}

Next is formatted to buttons.

#form-wrapper .button {
    float: right;
    margin: 10px 0 0 0;
    padding: 7px 15px;
    cursor: pointer;
    color: #fff;
    font: bold 13px Tahoma, Verdana, Arial;
    text-transform: uppercase;
    overflow: visible; /* IE6/7 fix */
    border: 0;
    background-color: #7089b3;
    background-image: linear-gradient(#a5b8da, #7089b3);
    border-radius: 3px;
    text-shadow: 0 1px 0 rgba(0,0,0,.3);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.5), 0 3px 0 rgba(0, 0, 0, 0.7);
}
 
#form-wrapper .button:hover {
    background-color: #a5b8da;
    background-image: linear-gradient(#7089b3, #a5b8da);
}
 
#form-wrapper .button:active {
    background: #64799e;
    position: relative;
    top: 2px;
    box-shadow: 0 0 3px rgba(0, 0, 0, 0.7) inset;
}

Đó là tất cả những gì mà chúng ta cần làm để có được một mẫu form liên hệ như ý muốn. Mình hy vọng các bạn sẽ học được nhiều qua bài viết này.

Chúc các bạn thành công !

Envelope Template HTML5 and CSS3 contact

To attract visitors to your Blog or web, you need a cool sample contact form to keep in touch with the user. In this article, I will share with you a sample contact form is designed as an envelope, you will not be able to use this template for your site, but you will learn a lot more from CSS3 properties as well as the HTML5 element in the design of the form.

Posted on 02-12-2015 

Comment:

To comment you must be logged in members.

Files with category

 
File suggestion for you
File top downloads
Codetitle.net - library source code to share, download the file to the community
Copyright © 2015. All rights reserved. codetitle.net Develope by Vinagon .Ltd