CSS for a line of code, I have spent two nights to think, the result is that the feeling ie a bit abnormal. With a normal idea,
FIREFOXAnd so the browser is no problem, only IE can not be. Only if you add a line of garbage code, IE can be displayed
1. The simple way, regardless, directly this can be:
Document.createstylesheet (). Csstext = ' label {color:red; ' +
This comment only helps understand in the current JS and is not written in CSS
' width:300px;height:150px} ' +
'. Class name {...} '
Article Introduction: CSS Page Production instance code: The triangle image of Sina Weibo.
Web Teaching network to provide the latest Web page production, Web design, Web page special effects, for personal sites to provide web
The following is the program code
With CSS you can not only change the background of the entire page you can also control
The background of other elements, such as P,div. This section we
The nature of the discussion will be
Color: Colors of
Like what:
. c1.c2
{
Text-decoration:underline;
}
In the selector. C1 and. C2 directly together, no space in the middle, no commas, what does that mean? Look at an example:
This is Red
This is Italic
Here are red, italic, underline
The
Article Introduction: CSS pseudo element before, after magical: the production of fashion focus picture frame
In CSS tags have such a label div:before, Div:after, for before, after the part of the people are quite unfamiliar, then these
Page-oriented design rather than browser-oriented design XHTML+CSS can achieve a flow layout, that is, as the length of the content automatically grow the region, and ultimately lead to the entire page growth, then the browser must display scroll
test Left Right The above code is the right fixed width, the left adaptive width, margin-right:-100px also shows that the size of the floating element is affected by the margin, above a width is 100% width minus 100pxHere adaptive is the use of the
Core tips: DIV CSS Column Navigation example, super cool resolution!
As shown in the picture effect:
First look at the XHTML code:
item one subitem one& lt;/li> subitem two subitem three subitem four item two item three item four
Take a
Core tip: This "browser default HTML CSS style attribute" is useful when you need to restore the default values. At the beginning, apply the wildcard selector *{margin:0;padding:0; When you need to use margins, you need to restore the HTML default
Core tip: using CSS to change the title beyond the part of ...
Software Station _ China's fastest and most secure software download Station _ Six anti-virus software detection
Although this is a good method, you can not control the program, but
Core Tip:In addition to controlling the position of the upper left corner of the positioning element, you can also control the width and height of the elements and the visibility of the elements in the page.
In addition to controlling the position
Core Tip: What is a type selector? A character that is the name of an existing label type in a Web page. The body is a type of tag in a Web page, Div,p,span.
One, type selector
What is a type selector? A character that is the name of an existing
Automatic line-wrapping problem, the normal character of the line is more reasonable, and continuous numbers and English characters will often be large containers, quite a headache, the following is a CSS how to implement the method of
Article Introduction: we have published a CSS text gradient, but in fact it's not a purely CSS-based gradient, it needs a translucent gradient png picture. Today we'll introduce two ways to implement text using CSS3.
Before, we have
Core tips: CSS background positioning background-position Negative has been difficult to understand the difficulties, on the one hand with less, on the other hand, the understanding of the lack of depth, today took a little time to seriously think
Quick tip:understanding CSS3 GradientsChinese: Understanding CSS3 GradientsPlease respect the copyright, reproduced please indicate the source, thank you!
The idea of creating a picture for a gradient is inflexible and will soon become a bad
Many of you may have heard a lot of rumors about CSS3, but what are the CSS3 techniques we can really use now? In this article, I'll show you some of the CSS3 tricks that are good in some major browsers (such as Firefox,chrome,safari,opera browsers).
There is a saying that good, table can do the effect, div omnipotent, on the contrary, not unexpectedly. Horizontally centered, with CSS set very simple, vertically centered, sometimes baffled some people. In the previous project did not encounter
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.