CSS Tutorial: Web page font and font size design

Font Size The CSS2 specification defines a font based on length-horizontal and vertical dimensions. This length is a numeric value and may be preceded with an optional plus (+) or minus (-) marker.   In addition, the value may have an optional unit identifier. In addition, the CSS2 specification defines two unit types: absolute units and relative units. The absolute value specifies the unit, and the relative unit specifies a value that is proportional to another value. The following list lists the relative unit identifiers: em: The height of the element font. It is calculated with the font size property of the element that uses the font ...

IE and FF incompatible page layouts CSS issues

CSS page layout will often appear a lot of IE and ff incompatibility problem, the following collation of some common possibilities and solutions! 1, with!important solution ie and Mozilla layout difference!important is the CSS1 definition of the syntax, the role is to improve the application of the specified style rules priority, the most important thing is: IE has not supported this syntax, and other browsers are supported. So we can use this to give IE and other browsers different style definitions, for example, we define this kind ...

Using CSS to solve the problem of automatic line wrapping in English words

Prevent form/layer bursting and prevent words from breaking the problem of automatic line wrapping in English words can be said to have tortured many people if a word is written very long, it will break the form, and the tube will be opened in English words. Prevent the form from bursting this problem has been mentioned by a lot of people, later in the earlier version of I also resolved, but caused the English word was broken into line, so the new template does not have to add some CSS code to control this. Today, I found the solution is simple. According to most articles on the Internet, just add in CSS: Code ....

Full-sweep CSS float

Clear floating a general do page people will encounter a thing, but whether we can clearly know, all-round understanding? So I was free to write such an article immediately, can not talk about everything, but the basic can give me what I know. Let's take a rough look at how many ways to clear the float (ie inside with zoom:1 will not write, the next topic to write). The corresponding DEMO uses pseudo class: After carries on the next empty system high level zero pseudo class layer eliminates uses the CSS Overflow:auto ...

Summary of common CSS style effects

Although CSS style learning requires us to do more practice, need to do more cases, think of thinking, but sometimes attention to the collection and collation of data is also very important, in the actual development will often play a multiplier effect. Rich content is also available in Www.phpq.net's documentation. Here are some common CSS styles for buttons, text boxes, and forms.   We can refer to it. One, button style. buttoncss {font-family: "Tahoma", "Song ...

CSS implements indent of first line of paragraph

Empty two words before the paragraph, do not use space.   You should use the first line indent text-indent. Text-indent can make the first line in the container indent a certain unit.   For example, Chinese paragraphs usually empty two characters before each paragraph. Here we need to know a length unit em. EM is the relative length unit.   The font size relative to the text within the current object. We usually empty two Chinese characters before each paragraph.   In fact, the first line is indented 2em. Look at the following example: <! DOCTYPE htm ...

CSS tips: Classic CSS usage techniques

Use Line-height to vertically center the line-height:24px;   If you use a fixed-width container and you want a row to be centered vertically, you can use Line-height (which is the same height as the parent container), and more vertically centered summaries are here.   Clear Container floating #main {overflow:hidden;   Before the period also mentioned this question, more information can see here. Do not allow links to be broken lines a {...

CSS implements table cells to force line wrapping and force no wrapping

Using CSS to implement table cell data automatically wrap or do not wrap 1, automatic line-wrapping: <style type= "Text/css" >. Autonewline {word-break:break-all;/* must/} </style> <table> <tr> <td class= "AutoNew ...

div Web layout and website design often make mistakes

1, navigation menu using pictures, Flash navigation menu using pictures, flash of course Bi Chunwen would have to look good, but the search engine does not know your pictures and flash. If you want to use a beautiful picture to navigate, you can use the background replacement method (I will talk about this method next time); If you want to use Flash to do the navigation, then I will not have your way. It is recommended to do a navigation menu link to the XML text submitted to the search engine. 2, improper use of the picture for the beautiful web page, often filled with pictures everywhere, this is not true, ...

The difference between padding and line-height

A friend raised a question, the difference between padding and line-height.   This is the basic knowledge of CSS, the box model knowledge and layout and related attributes are not very familiar with the time, it is very easy to confuse and not clear. In fact, padding is a layout setting that defines the inner margin of a container.   The line-height is the line spacing setting, which sets the row height of the object, such as text.   The padding is also called the inner margin, also known as padding to retrieve or set the patch margin for the four edges of the object. If you supply all four parameters ...

CSS to achieve vertical center 5 ways

Using CSS to achieve the vertical center of objects There are many different ways, it is difficult to choose the right method. Let me explain the good way I see it and how to create a good center site. It's not easy to use CSS to center vertically. Some methods are not valid in some browsers. Let's look at the 5 different methods that make objects vertical, and their pros and cons. (Take a look at the test page for a short explanation.) Method One of these methods is to set the display of some div as a table, so we can make ...

10 little-known CSS usage tips

10 little-known CSS usage tips 1.css font shorthand rules when you use CSS to define fonts you might do this: font-size:1em; Line-height:1.5em; Font-weight:bold; Font-style:italic; Font-variant:small-caps; Font-family:verdana,serif; In fact, you can abbreviate these attributes: font:1em/1.5 ...

CSS controls the picture to make it adaptive to the size code

The image automatically adapts to the size is a very common function, in the production time in order to prevent the picture to open the container and the picture size of the necessary control, we can use CSS to control the picture to make it adaptive size? Here are two ways to provide you, I personally recommend the first method of a CSS control picture size code <style type= "TEXT/CSS" > img {border:0; margin:0; padding:0; Max-w ...

CSS Web page making tutorial: Font Unit EM Introduction

Just learn Web page production, the teacher once told me to use CSS to enforce the definition of font size, or to ensure that everyone see consistent effect. This is particularly evident in the current Chinese site. including NetEase, Sohu, including most of these portal sites, with the absolute unit px (pixel). However, if you consider the usability of the site, the font size should be variable, some people who do not have good eyesight need to enlarge the font to see the content of the page. However, ie, which occupies most of the browser market, cannot adjust the size of the font that uses PX as the unit. Foreign people are very ...

Getting Started with CSS beginners: It's unwise to use a table layout page

Why is it unwise to use the table layout page? You see the title, do not think that the table can not be used in the page, but to use the table, but try not to use table to layout the page, why do you say so, because using the table layout page will lose the flexibility of the page, how a flexible method, For example, today you finally made out of the page, the next day the boss said I do not like the login module put to the right, or put to the left, notice plate put to the right, page style best one months for one, if you encounter such a boss ...

Save page as JS code

Save the page as two JS code in fact, a lot of time we need to put the content of the Web page directly to save as, the following we provide two JS save as a Web page code. <html> <head> <title> Save Web page </title> </head> <body> <object classid= "clsid : 8856f961-340a-11d0-a ...

Can control the picture to scroll JS code

This article collection of a picture of the scroll code to download the source, is a use of JS to achieve the advertising picture can scroll around the picture advertising code, which is from the Taobao station focus map code. <!doctype HTML PUBLIC "-//W3C//DTD XHTML 1.0 transitional//en" Http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional ...

Prompt to add Favorites when closing page and set home page JS code

1. Set homepage <script type= "Text/javascript" > Function Sethome () {this.style.behavior= "url (#default #homepage)"; This.sethomepage ("http://www.jzread.com"); Return ...

JS Check for URL code

JS check whether for the URL code in a lot of time to check whether for the URL code, verify that the URL is the correct format Oh, the following provides a JS authentication URL function, he can verify the HTTPS tutorial |http|ftp|rtsp|mms, there are ports. * * * Check whether the Web site * * @pa ...

JS does not contain Chinese characters or all Chinese functions

JS does not contain Chinese characters or all Chinese functions below provide three kinds of use JS to verify that there are Chinese characters or all of the JS validation function Oh, if you like to come in to download it.  function Ischinese (s) {var ret=true; for (Var i=0;i<s.length;i++) Ret=ret && (S.charcodeat (i) >=1000 ...

Total Pages: 21 1 .... 5 6 7 8 9 .... 21 Go to: GO

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.