Read "Mastering CSS: Advanced Web Standards Solutions"

Source: Internet
Author: User

Because I've been looking at the CSS: Advanced Web Standards Solution Recently, I've made some records. Because many developers dissatisfaction with the development of XHTML2, so there is WHATWG and the division of the World wide, WHATWG decided to develop their own norms, that is, HTML5, and the XHTML2 standard has been abandoned, HTML5 became the official standard of the world wide. The difference between XHTML and HTML is that XHTML adheres strictly to XML encoding rules, and the browser is based on the mime of the document. type to parse the document, and if it does not follow the specification, it will result in an error, while the HTML is very loose. DOCTYPE type and browser mode, DTD (document definition Type) is a set of machine-readable rules that define what is running in a particular version of XML or HTML and what is not allowed. The browser will act on the page and decide what behavior to take. The browser will see which DTD to use by analyzing the DOCTYPE of the page. add common rules that are used on all sites to form some kind of prototype CSS file, which can save more time. a pattern combination is a page or series of pages that use the current style sheet to display a combination of each style that may be absorbed on the site, from the heading level and text style to the specific content and layout type. the most basic style guide should describe general design guidelines such as rue handling headings and other typographic elements, what the grid structure is designed for, and which palette to use. IE7 and lower versions do not support the use of pseudo-class selectors on elements other than links, but all modern browsers support them. links should be used only for get requests and never for post requests. Write the form feedback information in the label label, then the absolute positioning is better? The CSS framework attempts to simplify the CSS layout by creating strong coupling between the markup and the presentation, but this coupling formally discards the main reason for table-based layout. To create a scalable and maintainable CSS in the same way, you should first examine the design and look for duplicate patterns, including patterns in the page structure or repeated occurrences of medium elements in the site. At this stage, we should not pay much attention to the way of expression, but should pay attention to structure and meaning. 1, first divide the page into large structured areas, such as containers, headers, page areas, and footers. 2, then focus on the content area itself and start building the grid structure. Look for common traits rather than visual representation. 3, then look for different layout structures in each area, whether you want to divide some information into two columns, three columns, or four columns. 4, after the design of the structure, you can now start to focus on different types of content. Give each content block a meaningful name, and then analyze their relationship. 5, look at the structure of each content block, to see whether there are common patterns in different types, rather than announcements and news in fact and the same. 6, it is good to start defining the elements that will be used immediately after identifying the pattern and determining the naming convention. in promiscuous mode ie5.x and IE6 do not support Margin:auto declaration, IE can be designed text-align:center to determine center,there are different ways to layout with CSS, including absolute positioning and the use of negative margins. to improve accessibility, I chose to place the wish content area in front of the secondary content area in the source code, which takes into account the screen reader because the screen reader does not have to go through unimportant content to reach the main content section. add display:inline to all floating elements. This precaution is used to prevent a bug in IE from being generated by an external bilateral margin.These two elements are nested within the CONTETN element and can create an association, and I take advantage of this fact, which has two benefits. Instead of creating a new class name for each element you want to apply, you should use cascading to find the element. This is a step that makes it easier to clear the float with floats. If you choose a framework, you might use it in every project, so the way you think is likely to become rigid. As the saying goes, if you have only one hammer, then everything looks like a nail. This toolkit can contain global reset, layout style and form processing, as well as login forms, calendar tables and navigation lists, and other common HTML-formed markup patterns. The most common CSS problem is not from browser bugs, but from the incomplete understanding of CSS specifications. IE is developing at a much slower pace than other browsers. The reset style sheet avoids and mitigates the problem of inconsistent HTML element default styles, one consistent stage across all browsers. I like the flow design with minimum width and maximum width. The mesh usually has a predetermined width, containing the specified number of columns and optional isolation. The grid is your best friend and can help you overcome the difficulties. It is the "middleman" between Photoshop and CSS that can help you make decisions about the initial positioning of floats, positions, margins, margins, borders, etc.

Read "Mastering CSS: Advanced Web Standards Solutions"

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.