Float from left : float « CSS Style « XML






Float from left


File: Data.xml

<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/css" href="Style.css" ?>
<review>
  <title>The title</title>
  <pullQuote>quote</pullQuote>
  <paragraph>
    A
    <reference>B</reference>
    C
    <keyword>XML</keyword>
    D.
  </paragraph>
</review>

File: Style.css

review {
   display:block;
   padding:10px;
   margin:10px;
   border-style:solid; 
   border-width:4px; 
   border-color:#000000;
}

title {
   display:block;
   font-size:24px;
   padding:5px;
   color:#FFFFFF; 
   background-color:#000000;
}

pullQuote {
   float:left;
   width:20%;
   font-style:italic;
   padding:10px; 
   margin:10px;
   border:solid; 
   border-width:4px; 
   border-color:#CCCCCC;
}

paragraph {
   display:block;
   padding:10px;
   border:solid; 
   border-width:4px; 
   border-color:#CCCCCC;
}

keyword {
   display:inline;
   font-weight:bold;
   color:#990000;
   border:solid; 
   border-width:2px; 
   border-color:#CCCCCC;
}

 








Related examples in the same category

1.floating right