white-space: pre : pre « Tags « HTML / CSS






white-space: pre

   
<!DOCTYPE html PUBLIC "-/pp/W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
    <head>
        <title></title>
        <style type='text/css'>
            body {
                white-space: pre;
            }        
        </style>
    </head>
    <body>
This is a test. 

   This is a test.     

    </body>
</html>

   
    
  








Related examples in the same category

1.'pre' renders text in a fixed-width or monospaced font
2.Use
 to keep the space
3.Pre Example
4.preformatted text in HTML
5.'width' determines the width of an element