[RESOLVED] [HTML] Question on indenting
I'm trying to figure out how to do a simple indent in HTML. I've read that CSS is really the best way to create an indent, however I want to work in pure HTML for now. From what I've read up on, there are 3 options(that I know of)
- Blockquotes
- Spacers
-
Which do y'all suggest? If not one of these, then what do y'all use?
Re: [HTML] Question on indenting
What exactly are you trying to indent? <blockquote> is just like a div but with more semantic meaning, so you can style that however you like with CSS. I wouldn't really use it for just indenting text arbitrarily, as the semantics point to it being a block of quoted text (similar to the inline <q>).
I'm not sure what you are referring to with "Spacers"? Is it the 1px gif thing? That went out of fashion in 1999....
should never be used for spacing/indenting. There is always a better way to do it.
If you want to indent the first line of a paragraph of text, then text-indent is what you're looking for. Otherwise, just assign padding-left or margin-left to the block-level element surrounding the content you want to indent. Also, try to always specify the padding/margin units in em instead of px.
Re: [HTML] Question on indenting
Spacers I've read were developed by netscape. I don't really know what it is to be honest. But the reason I don't want to us CSS yet is because I want to really understand HTML first before I start learning CSS. Using 5 times is really what I'm looking for the indent, but it doesn't look(or feel) right, that's why I wanted to know of a pure html indent.
Re: [HTML] Question on indenting
text-indent is what you're looking for... if it makes you feel better about not using CSS (crazy idea though it is) and being "pure" HTML, stuff it in the style attribute of the <p> tag... when it comes to formatting and positioning, you either have to start to embrace CSS, or at the least start using style attributes... but in reality html is about the content, not the look & feel.
And now I'm sure someone is going to argue this... what ever.
-tg
Re: [HTML] Question on indenting
Ok, being put like that it makes alot more sense now. So...
HTML - Content
CSS - Style
JavaScript/PHP - Interaction?
Re: [HTML] Question on indenting
Yeah, we could say that HTML is just for layouts. I mean like the basic structure of a building. And CSS is for styling. For example, the paints for this building.
Javascript is for clientside interaction. Means it would be executed at the client's browser. Whereas, a PHP code is server side. Means, it would be executed at the server and what it gives is the result of the execution!
:wave: