HTML/CSS/Text/sub — различия между версиями

Материал из Web эксперт
Перейти к: навигация, поиск
м (1 версия)
 
(нет различий)

Текущая версия на 08:17, 26 мая 2010

Changing ordered list markers to upper-roman

 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  <title>Changing ordered list markers</title>
  <style type="text/css">
  body { 
       line-height: 1.5em;
    }
    ol {
        list-style-type: upper-roman;
    }
  </style>
  
</head>
<body>
  <ol>
    <li>Combine.</li>
    <li>Gradually.</li>
    <li>Place.</li>
    <li>Transfer.</li>
    <li>divide.</li>
  </ol>
</body>
</html>



font size for Subscript and Superscript

 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="content-type" content="text/html; charset=utf-8" />
    <title></title>
<style type="text/css" media="Screen">
sub {
  vertical-align: -0.5em;
  font-size: 0.75em;
}
sup {
  vertical-align: 0.5em;
  font-size: 0.75em;
}
* .large {
  font-size: 32px;
}
sub {
  font-size: 0.9em;
}
sup {
  font-size: 0.9em;
}
</style>
</head>
<body>
<p class="large">A<sub>1</sub> B<sup>2</sup>C<sup>E</sup></p> 
</body>
</html>



To subscript text use sub tags

 
<?xml version = "1.0"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
   "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns = "http://www.w3.org/1999/xhtml">
   <head>
   </head>
   <body>
      <p>Only <sub>one</sub> download per hour is permitted.</p>
   </body>
</html>