span vertical-align: text-bottom; : span text « Tags « HTML / CSS






span vertical-align: text-bottom;

     

<!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'>
    <head>
        <title>vertical-align</title>
<style type='text/css'>
p {
    font: 12px sans-serif;
}
span.line {
    border: 1px solid rgb(200, 200, 200);
    background: rgb(244, 244, 244);
    font-size: 100px;
}
span.line span {
    vertical-align: 300%;
    font-size: 20px;
    background: white;
    border: 1px solid black;
}
span#top {
    vertical-align: top;
}
span#middle {
    vertical-align: middle;
}
span#bottom {
    vertical-align: bottom;
}
span#text-top {
    vertical-align: text-top;
}
span#text-bottom {
    vertical-align: text-bottom;
}
</style>


    </head>
    <body>
        <p>
            The vertical-align property is used in two scenarios: to
            vertically align inline elements with respect to the line
            box, and to vertically align the contents of table cells.
        </p>
        <p>
            When vertically aligning inline elements within a line box,
            the vertical-align property can be used with the keywords
            top, middle, bottom, text-top, text-bottom.
        </p>
        <p>
            <span class='line'>
                Gg
                <span id='top'>Top</span>
                <span id='middle'>Middle</span>
                <span id='bottom'>Bottom</span>
                <span id='text-top'>Text Top</span>
                <span id='text-bottom'>Text Bottom</span>
            </span>
        </p>
    </body>
</html>

   
    
    
    
    
  








Related examples in the same category

1.Span text-transform: uppercase;
2.Span text-align: center;
3.span text-decoration: underline;
4.span text-decoration: overline;
5.span text-decoration: line-through;
6.span text-decoration: blink;
7.span text-decoration: underline overline;
8.span text-decoration: underline line-through;
9.span text-decoration: overline line-through;
10.span text-transform: lowercase;
11.span text-transform: capitalize;
12.span vertical-align: text-top;
13.text-indent does not work on inline elements
14.When vertically aligning inline elements,the vertical-align property can be: top, middle, bottom, text-top, text-bottom.
15.Inline vertical-align: text-bottom
16.Inline vertical-align: text-top