I am using the p tag to align text left and right on the same line using:
.left
{
float: left;
text-indent: 5px;
margin-top: 0px;
}
.right
{
float: right;
text-indent: 5px;
margin-top: 0px;
}
<div id="content">
<p class="left">Left Text </p>
<p class="right">Right Text </p>
</div>
The left text will indent by 5 pixels, the right text will not. I have tried -5px and just 5px, any ideas how I could do this?
Thanks
You can use margin-left and margin-right instead. Or padding-left and padding-right depending on your desired output/requirement.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With