It is necessary to master some Cross-browser compliant CSS coding guidelines.
First: Understand the CSS box model (learning div+css layout is also very important, learn the CSS box model to learn DIV+CSS is not difficult)
A thorough understanding
In order to let everyone understand the role of CSS, and why to use CSS instead of HTML tables for page layout, the following is explained by an example. One of the pages is formatted with HTML and another page is formatted with CSS.
HTML
before doing web pages, only consider the compatibility of IE6 and FF, the company changed, the request is also high, FF and IE 6 7 8 to be fully compatible,
Met to be alone hack IE8. Of course, it is very convenient to use annotations, just add
In today's web age, which advocates usability design and user experience design, CSS is also involved. Most people in the CSS code is always defined in the overall font size, in the Chinese case is generally 12px, and in fact, in this way, in the
Use some spaces to achieve a Chinese alignment or width equal to the number. See table below:
of which and &emsp, because of a certain super features, so that it can board the web session stage! What characteristics? As shown in the above
Block elements are generally container elements of other elements, and block elements are generally started from new rows, which can hold inline and other block elements, and common block elements are paragraph label ' P '. "Form" is a special block
CSS page layouts should avoid abusing DIV elements that have been advocated by us, and organizing documents with appropriate HTML tags is the basis for CSS page layouts.
The use of DIV and span elements in a page is a new problem and we can easily
div CSS Page Layout There are a lot of places to learn, here and you focus on the div CSS hidden content style method, I believe this article will let you have some harvest. DIV css Hidden content style method css hidden use 1, the text of the
The application of HTML and CSS in Flash:
I accidentally saw my colleague Den getting a little something: using HTML and CSS in Flash, the code is this:
Example Source Code
var myStyle:TextField.StyleSheet = new Textfield.stylesheet ();
The syntax for CSS paragraph indentation is as follows:
Syntax: Text-indent:〈 value
Allowable value: Length 〉| Percentage
Initial value: 0
The text indent attribute can be applied to block-level elements (P,H1, etc.) to define the number of
When we design the page, we will encounter the child Div to control the inside of the parent div fixed position, but also the layer up and down relationship. Here's a little trick.
The position of the parent Div uses the relative, the position
Font-size:1.5em;
In fact, in foreign CSS writing, using EM as a unit is a lot of human considerations, the second is the United States Department of Labor Section508 Act imposed restrictions. So in web design, there are three kinds of metric units
css| Standard | skills | Web page
Of course, to generate thumbnails of this work if the program to complete, the effect will be much better, but sometimes for some reason, such as the server does not support GD and so on, it is inevitable to ask for
css| Standard | beginners
Beginner's tutorial, mainly tells you to learn CSS is not difficult.
The CSS layout advocate's voice is being overwritten by the sound of "table layout benefits". One myth is that CSS is hard to learn. In fact, CSS is no
CSS a landscape picture, when the mouse in the picture above, immediately display the text description of the picture, and the text of the local image becomes blurred, when the mouse moved away from the picture, the picture on the text disappeared
css| Filter When you use the "Glow" attribute on an object, the edge of the object produces a glow-like effect. Its expression is as follows:
Filter:glow (Color=color,strength=strength)
There are only two parameters for the Glow property: Color is
css| Dynamic | Transformation by setting properties in CSS, we can define exactly the style of a page, such as color, font, border, and so on. Now we want to talk about the CSS positioning is mainly in the layout and control of the page to define,
CSS 1. Block and inline element comparisons
All HTML elements are part of block and inline.
The block element is characterized by:
Always start on a new line;
Height, row height and top and bottom margins are controllable;
The width defaults to 100%
Css
The minimum height can be set a box of the minimum height, when its content less time, can also keep box height is certain, beyond the automatic downward extension, but so far, only opera and Mozilla support, IE7 began to support, but IE7 in the
This article describes the CSS implementation of adaptive width of the menu button effect code. Share to everyone for your reference. Specifically as follows:
This is a CSS based on the adaptive width of the button effect code, this effect you can
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