sircharlo Posted July 27, 2007 Share Posted July 27, 2007 Hi, everyone !I have a problem with the CSS float property. I have this HTML: <p class="top"><a href="#Top">Retour à l'index</a></p> <p class="ask"><a class="ask" title="Question?" href= "question.html">Vous avez des questions à ce sujet? Cliquez ici</a></p> and this CSS: p.top { float: left; text-align: left; font-size: .9em; } p.ask { float: right; text-align: right; font-size: .9em; color: #f751b9; } a.ask { color: #f751b9; float: right; text-align: right; } This gives me this output in IE (which is the one I want):But in FF I get this:How do I fix this ?Thanks.P.S. If you could also tell me why my link color is the default color even though I specified another, I would apreciate . Link to comment Share on other sites More sharing options...
pulpfiction Posted July 27, 2007 Share Posted July 27, 2007 Try this...p.top { float: left; text-align: left; font-size: .9em; } p.ask { text-align: right; font-size: .9em; color: #f751b9; } a.ask { color: #f751b9; float: right; text-align: right; } Link to comment Share on other sites More sharing options...
sircharlo Posted July 27, 2007 Author Share Posted July 27, 2007 That gives me in FF (in IE it is still fine):Is there a way to align the left paragraph to the top? Link to comment Share on other sites More sharing options...
Synook Posted July 28, 2007 Share Posted July 28, 2007 Try adding "clear:none;" to the paragraph styles Link to comment Share on other sites More sharing options...
sircharlo Posted July 30, 2007 Author Share Posted July 30, 2007 Thanks for all your help everyone, I found a solution to my problem. Here's my HTML and CSS: <span class="ask"> <a class="pink" title="Question?" href="question.html"> Vous avez des questions à ce sujet? Cliquez ici</a></span> <span class="top"><a href="#Top">Retour à l'index</a></span> .top { float:left; vertical-align: top; text-align: left; font-size: .9em; } .ask { text-align: right; font-size: .9em; color: #f751b9; } a.pink { color: #f751b9; float: right; text-align: right; } Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.