I learned some detailed summary of html and CSS in the recent period, htmlcss

Source: Internet
Author: User

I learned some detailed summary of html and CSS in the recent period, htmlcss

1. border rounded corner attribute: border-radius. The value can be a percentage or custom length. Negative values cannot be obtained. If it is a circle, set the height and width to equal, and set border-radius to 100%
2, IE6, IE7, IE8, opera, firfox-2.0 and other browsers, does not support border rounded corner effect. We can use images.
3. In order to overcome the problem that some browsers cannot display certain attribute settings, you can set specific settings for recognition. For example, Firefox is-moz-, Google is-webkit-, and applications are as follows: -webkit-border-radius: 100%;
4. Attribute elements such as input can be set as follows in style (text can be other ):
Input [type = "text"] {
Width: 50px;
...... (Other property settings)
}
5. You can use outline: none to remove the border of the input form. However, even if outline: none; is set, the border is not removed. In this case, you can use border: none; to solve this problem.
6. Sometimes you can use the unordered list ul and li to implement some elements in the same row, because the list is a block-level element, at this time, we can use the floating element to convert each column of the list item into an embedded element, so that they are displayed in the same row.
7. Sometimes, when we use input for the search box, we often set the initial value in the search box. When the user clicks, the initial value disappears, except for the javascript event, you can also use the placeholder attribute. For example, <input id = "search" name = "search" placeholder = "please input what you want..."/>
8. When using input for some input boxes, such as password boxes and user names, you should set the maximum length of input to avoid unlimited input.
9. the height and width of an embedded element cannot be set, but the padding and left and right margins can be set.
10. Add word-break: break-all to the declaration block;
The best reference snippets are word-wrap: break-word; overflow: hidden;
Other pieces that can be referenced are word-wrap: break-word; overflow: auto;
Also, word-wrap: break-word; word-break: break-all;
11. Sometimes we need to place one of our tasks in the center of the entire page. We can set the margin value for implementation. Set margin: 0px; margin: auto.
12. You can set the padding attribute if you do not want the content to top or close to the edge of the div, but remember to change the width and height of the original settings to ensure the original size. The principle is that the content area of an element is defined by width and height, but the background color and image of the element can be displayed in padding.
13. To prevent the content of the floating element from affecting the subsequent content, you can set clear: left/right in the Declaration block of the subsequent element. Then, set the floating of the following elements.
HTML/CSS/JavaScript standard Tutorial: instance version learning Summary

This kind of spam book that even the author's name does not dare to write should not be read, it is a waste of money and a waste of time. Find some classic imported books.
 
Do you have any experience in learning HTML, CSS, and JavaScript? Tell me something

HTML + CSS is much simpler than JavaScript. JavaScript is very important and you should study it well! It will be helpful for you to learn Ajax and Jquery in the future! It is also very important in the enterprise, so you should study hard!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.