/    Sign up×
Community /Pin to ProfileBookmark

A real basic question I expect… indenting?

I very new to all this html stuff (just started today) and haven’t been able to work out how to indent. I have a list and although I don’t want it centred, I do not want it right up against the left margin.
Thanks

to post a comment
HTML

14 Comments(s)

Copy linkTweet thisAlerts:
@Player_11Apr 24.2006 — couldn't you just use   a couple of times to get that effect?
Copy linkTweet thisAlerts:
@HoweauthorApr 24.2006 — Yes I tried that but I needed a lot of them. Is that the best way to do it then?
Copy linkTweet thisAlerts:
@ray326Apr 24.2006 — Something like so.

ul { list-style:none; margin:0; padding:0 }

li { margin-left:2em }

Better yet, check http://www.alistapart.com/articles/taminglists
Copy linkTweet thisAlerts:
@Player_11Apr 24.2006 — <blockquote> First Word Here Line Here </blockquote>

Maybe?? but the next line is double spaced from the first so it looks wierd

so i think the &nbsp; is the best way to go unless im missing something
Copy linkTweet thisAlerts:
@KeveyApr 24.2006 — Look at Ray's recommendation above...his way is the best way to go about it. The ul { list-style:none; margin:0; padding:0 } li { margin-left:2em } info would go between <style> tags or externally in a css file. ?
Copy linkTweet thisAlerts:
@HoweauthorApr 24.2006 — Still not getting it! Do I put the ul and li in <>tags separately or with the list-style. Really am new to this talk to me like I'm a 5 year old
Copy linkTweet thisAlerts:
@thereseApr 24.2006 — Since this is your first day at html, you will need a little more direction than those above have given you!

To make a list, code your html like this:

<ul>Bulleted List

<li>list item 1</li>

<li>list item 2</li>

<li>list item 3</li>

<li>list item 4</li>

</ul>


<ol>Numbered List

<li>list item 1</li>

<li>list item 2</li>

<li>list item 3</li>

<li>list item 4</li>

</ol>

<ul>Extra space<br>

<li>list item 1</li><br>

<li>list item 2</li><br>

<li>list item 3</li><br>

<li>list item 4</li><br>

</ul>

This should get you started with lists. The suggestion to visit A List Apart website is good and you will learn a lot more about making lists. But since its your first day, it might be a bit overwhelming.

I wouldn't use the "&nbsp; ". It just puts a lot of garbage in your coding and makes your html file really hard to read!

Don't forget to learn about using style sheets as you are learning html. You will be able to change the appearance of your list (among other things).

Good luck.
Copy linkTweet thisAlerts:
@thereseApr 24.2006 — PS: The coding Ray is showing you goes in the style sheet. If you haven't learned about style sheets, don't worry about that right now.
Copy linkTweet thisAlerts:
@HoweauthorApr 24.2006 — Thanks for that. I think I am trying to get a little ahead of myself. I'm very pleased with what I've worked out today, so I think I'll leave it at that for now
Copy linkTweet thisAlerts:
@ray326Apr 25.2006 — <blockquote> First Word Here Line Here </blockquote>[/QUOTE]Never use a semantic element for presentation. A "blockquote" [B]means [/B]something, it doesn't [B]look like[/B] something.
Copy linkTweet thisAlerts:
@felgallApr 25.2006 — <ul>[b]Bulleted List[/b]

<li>list item 1</li>

<li>list item 2</li>

<li>list item 3</li>

<li>list item 4</li>

</ul>


<ol>[b]Numbered List[/b]

<li>list item 1</li>

<li>list item 2</li>

<li>list item 3</li>

<li>list item 4</li>

</ol>

<ul>[b]Extra space<br>[/b]

<li>list item 1</li><br>

<li>list item 2</li><br>

<li>list item 3</li><br>

<li>list item 4</li><br>

</ul>
[/QUOTE]


The parts I have marked in bold are invalid and will report as errors if you try to validate your HTML. Nothing can go between the <ul> or <ol> tag and the first <li> as lists can only contain <li>s and everything else has to be inside of those <li> tags.
Copy linkTweet thisAlerts:
@thereseApr 25.2006 — Absolutely true Stephen, I should have done it this way:


Bulleted List

<ul>

<li>list item 1</li>

<li>list item 2</li>

<li>list item 3</li>

<li>list item 4</li>

</ul>

Numbered List

<ol>

<li>list item 1</li>

<li>list item 2</li>

<li>list item 3</li>

<li>list item 4</li>

</ol>

Extra space

<ul>

<li>list item 1</li><br>

<li>list item 2</li><br>

<li>list item 3</li><br>

<li>list item 4</li><br>

</ul>

Therese
Copy linkTweet thisAlerts:
@WebJoelApr 25.2006 — Never use a semantic element for presentation. A "blockquote" [B]means [/B]something, it doesn't [B]look like[/B] something.[/QUOTE]

I was guilty of doing that in my early days and months of webpage building. A "blockquote" makes the selected 'block of text' appear to be 'indented' when viewed on the computer, indented on the left and right sides.

BUT it was intended to be used only for showing actual quoted material like someone's speech, etc. Screen readers treat 'blockquoted' material differently, and it expects to find 'quoted text', not just general content/text, hyperlinked material, etc.

Using it for anyting else is akin to, say, inserting "content text" into an <img src="~"> tag and expecting it work (although here, it won't work anyway). Heed the wise words, don't use 'blockquote' for things that aren't actual quoted content. :-)
Copy linkTweet thisAlerts:
@ray326Apr 25.2006 — I was guilty of doing that in my early days and months of webpage building.[/QUOTE]Hey, we ALL were. I'm reworking an old site now where I used it extensively. UGHH! That's what comes of using WYSIWYG editors. They'll have an "indent" button on the toolbar and guess what it does. ?
×

Success!

Help @Howe spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.21,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...