The first method margin method, the original code as shown in the figure.
#nei的margin的左右上下的边距. Get the center effect.
The second method. Pisition method, the location of the center is computed by absolute positioning, the code is as
IE vs FF CSS Compatibility essentials: DOCTYPE affects CSS processing Ff:div Set Margin-left, Margin-right is already centered when auto, IE not good ff:body set text-align, Div needs to set Margin:auto (mainly margin-left,margin-right) to
The use of CSS for the first line indentation, very convenient.
Wrap the content of the article with a P tag, and then add a style to the tag
Instance:
" > first paragraph second paragraph
then we'll add the style
to the CSS. . Context
The behavior of the NoWrap property in the TD element is related to the width property of the TD element. If the TD width is not set, the NoWrap property works, and vice versa. We can implement a newline by setting the Word-break:break-all for
CSS defines hyperlinks in a sequential order. Otherwise, there may be bugs in some browsers where a style does not work. The desired effect is not displayed correctly.The order in which CSS properties are arranged: L-v-h-a.L-v-h-a is a shorthand for
Dynamic Additions to Styles:(where the red font is a dynamically added-style statement), a function that dynamically generates unordered lists to display the search for WiFi signals, which have 3 parameters, the name of the WiFi, the encryption
In Baidu music http://music.baidu.com/see such a picture effect, when the mouse moved up, there will be a flash in the picture across, the effect is very cool. So the effect can be realized again:The general idea is that the design of a transparent
CSS style text-align:center in the IE7, there must be a lot of friends have encountered it, the following has a good method, we can refer to the hope for everyone to help
Copy Code code as follows:Body{Text-align:center;}
Open with IE7 is
Mouse over change the effect of text must be a lot of friends have encountered it, this article for you to introduce how the CSS is achieved, interested friends can understand the next
Copy Code code as follows:
Mouse rollover text
Cascading style Sheets (CSS), translated as "cascading style sheet" or "Cascading style sheet", also referred to as "style sheet."
The introduction of CSS is used to extend HTML, not to replace HTML. In other words, CSS is inseparable from HTML, it
There are many attributes that are rarely used in CSS, but these properties are sometimes discovered and immediately cause some people to chase them, which is the result of the first word capitalization. Recently more and more bloggers began to use
Basic knowledge of application
The application of CSS is not difficult, but please refer to the basic understanding here, some words have a little basic concepts, for you look at the back of the teaching will be helpful, it looks like it will not
In the Div+css layout, this is generally the case for the overall architecture:
and for the header section, certainly to display the site title, in addition to displaying the site title, you may want to show other important objects, such as the
When making a Web page, there is often a situation where we need to put a picture of an unknown size in a fixed-width container, at which point we need to consider the question:Only one of the width or height settings for a picture can be scaled
Move the background image to the left and use the background positioning properties more familiar friends should be easy to do, here is a good example, not friends can refer to the
The upper-left corner of the background picture is relative to the
Use CSS to write a table, do not doubt, mainly on the HTML structure of the CSS style redefinition, we can see the effect map, personal feeling is also good, interested friends can refer to the
Copy Code code as follows:
content=
In order to make all browser fonts unified, you need to load the remote font through the CSS, there is a good example, we can refer to, I hope to help you
Copy Code code as follows:
*china*Results
The load order of style and class in the end who first, who will cover who, in the next example would be a detailed introduction, I hope to help you
Copy Code code as follows:test Click to try
This style of writing will not overwrite the cursor
Positioning, the parent div set position:relative, the child Div Position:absolute will be relative to the parent div for absolute positioning, next for you to introduce the CSS position attributes in the div layer application
Originally only
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