Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CSS second-line indent not working

Tags:

css

Page in question: http://www.rjlacount.com/public/lander/

I'm probably just doing something stupid, but I'm trying to indent the second line of wrapping text inside the form (with "Your account: [email protected]" at the top) and I can't seem to get anything to work.

I would think the solution is:

form span {padding-left:1.5em;text-indent:-1.5em;}

but this only seems to indent the first line of each section.

Another look at this would be much appreciated, thanks!

like image 716
R.J. Avatar asked Jun 09 '11 18:06

R.J.


2 Answers

If the element is inline it will indent the first line, otherwise if it's a block element it will indent the rest of the lines, which is just like Briguy37 said, since that's the difference between DIV and SPAN. I just wanted to clear out that it's not a "problem with span".

like image 145
Omer Tuchfeld Avatar answered Sep 22 '22 00:09

Omer Tuchfeld


For some reason, this works with a DIV, but not with a SPAN. Not really sure why, but here's a fiddle with the same CSS for both.

like image 34
Briguy37 Avatar answered Sep 22 '22 00:09

Briguy37