Basics of HTML

  1. Terms and Definitions
  2. Principles of WEB 2.0
  3. The structure of the HTML-document
  4. Main metatags
  5. Formatting Text HTML
  6. Lists html-page
  7. Text fixed format
  8. Selected text html-page
  9. Change font options
  10. Graphics html-page
  11. Tables html-page
  12. Hyperlinks
  14. Frames


  1. What is CSS
  2. CSS syntax
  3. Style classes
  4. Combined styles
  5. CSS table
  6. CSS cascading rules
  7. Recommendations applying styles
  8. Font options
  9. Line breaks, vertical alignment
  10. Background settings
  11. Parameters of the paragraph
  12. List options
  13. The parameters of the cursor
  14. Options indentation
  15. Parameters frame
  16. Parameters selection
  17. Display options
  18. Containers


Line breaks

The default browser breaks lines of text so that there is no horizontal scroll bar, which indicates the presence of bad style web design. To this end, the browser converts the gaps (if present in the text) in one space; Breaks are also converted to spaces. Browser "at their discretion" breaks the line so that they fit in the browser window width.

The style attribute white-space allows the webmaster to change the rules that govern the browser when displaying text on the screen.

Possible values are white-space:

Tag <PRE> allows you to display the text as it appears in a html-code, it is often very convenient. The main "flaw" tag <PRE> is that long lines are not broken, so may cause the horizontal scroll bar. This can be avoided quite simple, if you enter a style that will determine the tag <PRE> :


PRE {white-space: pre-wrap}

The style attribute word-wrap allows you to specify the location in which the browser can break text:


P {word-wrap: break-word}

Vertical text alignment

The style attribute of the vertical alignment of text vertical-align rarely used (more often it is used in the tables). Most often the text includes a superscript or subscript (in the mathematical, physical and chemical formulas), which is much more convenient to set the tags <SUB> and <SUP> .

Possible values vertical-align:

It should be understood that the use of the vertical alignment of text has a lot of values that are in different cases give different results, so to use vertical-align should be with caution.

Parameters of the shadow of the text

Parameters of the shadow of the text defines the style attribute text-shadow .

text-shadow: <color> <horizontal offset> <vertical offset> [<blur radius>]

P {text-shadow: red 0px 0px 1pt}

In this example, the shadow is located just below the text, and refers to himself only by smearing.