chelnov63 Posted September 2, 2008 Share Posted September 2, 2008 I have the following code: <div style="width: 420px; height: 275px; overflow:auto;"> <span>01/01/70</span><span class='stuff' style='padding-left:45px'>This is a long title</span> <span style='padding-left:95px'><a href='news.php?id=5'>Read More</a></span><br> <span>01/01/70</span><span style='padding-left:45px'>small title</span> <span class='stuff' style='padding-left:95px'><a href='news.php?id=4'>Read More</a></span><br> </div> The output looks like: 01/01/70 This is a long title Read More 01/01/70 small title Read More However I want the Read More's to be in line with each other.. i cant use a table since this div tag uses autoscroll bars when the content increases... any help is appreciated.. Quote Link to comment https://forums.phpfreaks.com/topic/122364-css-alignment/ Share on other sites More sharing options...
dropfaith Posted September 2, 2008 Share Posted September 2, 2008 i wouldnt use spans for this id use divs to move the content will give you more play with wdiths and text alignments <div style="width: 420px; height: 275px; overflow:auto;"> <div class="date" style="width:120px;float:left;">01/01/70</div> <div class="stuff" style="width:120px;float:right;">Read More</div> <div class="title" style="width:170px;">Titles</div> </div> Quote Link to comment https://forums.phpfreaks.com/topic/122364-css-alignment/#findComment-631833 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.