html - CSS - Styling small details with <p> -


i need make this:

how should looks like

i made this: enter image description here

demo: http://jsfiddle.net/slck9/2/

it looks problem right put button , text "4x reakce" on same line , right positions, can't self, there chance can me it?

my html:

<span id="article-container">  <ul>       <li><a href="#"><img src="images/foto.jpg" width="109" height="109" alt="popis"></a>             <h2><a href="#">název článku</a></h2>             <p><span><strong>28. 2. 2014 8:29</strong> od dwandy</span><br>               ahoj, jak se máš? já úplně úžasně úpe nejvíc. závidíš, he? </p>             <p class="more"><a href="#" class="links">přečíst</a><br>               <a href="#">4 reakce</a></p>             <hr>        </li>    <li><a href="#"><img src="images/foto.jpg" alt="popis"></a>            <h2><a href="#">název článku</a></h2>            <p><span><strong>28. 2. 2014 8:29</strong> od dwandy</span><br>              ahoj, jak se máš? já úplně úžasně úpe nejvíc. závidíš, he? </p>            <p class="more"><a href="#" class="links">přečíst</a><br>              <a href="#">4 reakce</a></p>            <hr>       </li>        <li><a href="#"><img src="images/foto.jpg" alt="popis"></a>            <h2><a href="#">název článku</a></h2>            <p><span><strong>28. 2. 2014 8:29</strong> od dwandy</span><br>              ahoj, jak se máš? já úplně úžasně úpe nejvíc. závidíš, he? </p>            <p class="more"><a href="#" class="links">přečíst</a><br>              <a href="#">4 reakce</a></p>            <hr>       </li>  </ul> 

css:

#article-container{   width: 960px;     margin: 0 auto;     color:#4d4d4d;     font-size:90%   height: 144px; }  #article-container br, hr {     display:none; } #article-container ul {     width:960px;   height: 144px     overflow:hidden;     margin:0;     padding:15px 0; } #article-container li {     width:320px;     float:left;     list-style:none;     padding:0;     margin:0 } #article-container img {     float:left;     margin: 0 10px 0 0 } #article-container img {     border:2px solid #999e8a } #article-container a:hover img {     border-color:#000 } #article-container h2 {     margin: 0;     padding: 0 0 10px 0;     font-size:110%;     font-weight:normal; } #article-container h2 {     color:#4d4d4d } #article-container h2 a:hover {     color:#840000 } #article-container p {     padding: 0 10px 0 0;     margin:0 } #article-container p span {     display:block;     padding: 0 0 5px 0 } #article-container p.more {     padding: 0px 0 0 0;     overflow:hidden } #article-container p.more {     color:#2e79bc } #article-container p.more a:hover {     color:#840000 } #article-container p.more a.links {     float:right;     padding: 5px 10px;     background:#2e79bc;     color:#fff;     margin-right:15px;     text-decoration:none;     border-radius:3px; } #article-container p.more a.links:hover {     background:#000 } 

changing line height worked me :

#article-container p.more {     color:#2e79bc;     line-height: 27px; /* try changing , see happens */ }  #article-container p.more a.links {     float:right;     padding: 5px 10px;     background:#2e79bc;     color:#fff;     margin-right:15px;     text-decoration:none;     border-radius:3px;     line-height: 18px; /* try changing , see happens */ } 

demo here : http://jsfiddle.net/slck9/4/


Comments

Popular posts from this blog

windows - Single EXE to Install Python Standalone Executable for Easy Distribution -

c# - Access objects in UserControl from MainWindow in WPF -

javascript - How to name a jQuery function to make a browser's back button work? -