Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

HTML Forum


You are currently viewing our HTML Forum as a guest. Please register to participate.
Login



Post a Project »

Find a Professional HTML Freelancer!

Find a Freelancer to help you with your HTML projects

FREE Outsourcing eBook!

Reply
Old 03-25-2007, 10:44 AM Nested List
Ultra Talker

Posts: 316
Trades: 0
I'm trying to do a nested list but its not really working out for me.

This is the list I have:
<UL> Numbers:
<LI> one
<LI> one.two
<LI> one.three
<LI> four
<LI> five
</UL>

I want 'one.two' and 'one.three' to be indented.

Does that make sense?

Thanks.
Joe3000 is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 03-25-2007, 10:47 AM Re: Nested List
LadynRed's Avatar
Defies a Status

Posts: 10,017
Location: Tennessee
Trades: 0
Then you have to actually nest the lists:
<ul>
<li>one
<ul>
<li>one.two</li>
<li>one.three</li>
</ul>
</li>
<li>four</li>
<li>five</li>
</ul>
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 03-25-2007, 10:48 AM Re: Nested List
Ultra Talker

Posts: 316
Trades: 0
Thanks.

Just tried that but am using custom bullets and they have gone funny!

Do I need to do something else?



ul {
list-style-type: none;
padding-left: 0;
margin-left: 0;
margin-top: 0px;
margin-bottom: 0px;
}
li {
background: url(images/arrow_double.png) left center no-repeat;
padding-left: 15px;
margin-left: 0px;
margin-top: 0px;
margin-bottom: 0px;
line-height: 130%;
}
Attached Images
File Type: png list.PNG (2.4 KB, 24 views)

Last edited by Joe3000; 03-25-2007 at 11:09 AM..
Joe3000 is offline
Reply With Quote
View Public Profile
 
Old 03-25-2007, 11:27 AM Re: Nested List
Banned

Posts: 905
Name: Travel Agent
Trades: 0
Can you show us the site you're doing this on, so we can see your code? You might also want to use this as a reference for placing custom bullets.
travelagent is offline
Reply With Quote
View Public Profile
 
Old 03-25-2007, 11:33 AM Re: Nested List
Ultra Talker

Posts: 316
Trades: 0
http://londonlabs.co.uk/test/
Joe3000 is offline
Reply With Quote
View Public Profile
 
Old 03-25-2007, 11:37 AM Re: Nested List
LadynRed's Avatar
Defies a Status

Posts: 10,017
Location: Tennessee
Trades: 0
You need to use specificity to target the bullet, or absence of a bullet, for the nested list:

<ul id="numbers">
<li>one</li>
<ul>
<li>one.one</li>
<li>one.two</li>
</ul>
<li>two</li>
<li>three</li>
</ul>

#numbers{
list-style: square;
}
#numbers ul li {
list-style: upper-alpha;

}

Or, without an ID
ul{
list-style: square;
}
ul ul li {
list-style: upper-alpha;

}

I see you found your paint splatters
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 03-25-2007, 12:08 PM Re: Nested List
Ultra Talker

Posts: 316
Trades: 0
Yeah I found the paint!

I still don't get it though.

I've tried your example but I can't adjust it to work with what I have and what I want.
Joe3000 is offline
Reply With Quote
View Public Profile
 
Old 03-25-2007, 03:04 PM Re: Nested List
Tom_M's Avatar
Ultra Talker

Posts: 250
Name: Tom Maurer
Location: Pennslvania, USA
Trades: 0
Maybe something like this? You can tweak the padding and margin to what you want maybe.

Code:
	
ul {
    list-style-image: url(images/arrow_double.png);
    padding: 0;
    margin: 0 0 0 20px;
}

li {
    line-height: 130%;
}
li ul {
    list-style: none;
}
Tom_M is offline
Reply With Quote
View Public Profile
 
Old 03-25-2007, 03:50 PM Re: Nested List
Ultra Talker

Posts: 316
Trades: 0
Thanks, that seems to have done it.
Joe3000 is offline
Reply With Quote
View Public Profile
 
Old 03-25-2007, 09:01 PM Re: Nested List
Banned

Posts: 905
Name: Travel Agent
Trades: 0
Joe - if you want them indented, you can write your HTML like this:

<a href="http://www.yoursite.com">»&nbsp;Your Link Here</a><br>
<a href="http://www.yoursite.com">»&nbsp;Your Link Here</a><br>
<a href="http://www.yoursite.com">»&nbsp;Your Link Here</a><br>
<a href="http://www.yoursite.com">»&nbsp;Your Link Here</a><br>
travelagent is offline
Reply With Quote
View Public Profile
 
Old 03-26-2007, 11:10 AM Re: Nested List
Ultra Talker

Posts: 316
Trades: 0
Isnt that cheating?
Joe3000 is offline
Reply With Quote
View Public Profile
 
Old 03-26-2007, 02:46 PM Re: Nested List
LadynRed's Avatar
Defies a Status

Posts: 10,017
Location: Tennessee
Trades: 0
You would indent using margin and/or padding on the ul, li or a tags.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 03-26-2007, 04:04 PM Re: Nested List
Banned

Posts: 905
Name: Travel Agent
Trades: 0
Quote:
Originally Posted by Joe3000 View Post
Isnt that cheating?
I don't understand -- how is that cheating?
travelagent is offline
Reply With Quote
View Public Profile
 
Old 03-27-2007, 04:36 AM Re: Nested List
Ultra Talker

Posts: 316
Trades: 0
Quote:
Originally Posted by travelagent View Post
I don't understand -- how is that cheating?
Using spacing instead of positioning/margins.
Joe3000 is offline
Reply With Quote
View Public Profile
 
Old 03-28-2007, 05:34 AM Re: Nested List
chrishirst's Avatar
Missing! presumed drunk.

Posts: 42,383
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
Huh?

If you need something that simple and it works, then use something that simple.

Just because you could use margins and positioning doesn't mean you have to
__________________
Chris. ->>
Please login or register to view this content. Registration is FREE
<<-

A foolish consistency is the hobgoblin of little minds
Thought for today:- Is SEO the only industry where all the cowboys are Indians?
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 03-28-2007, 10:39 AM Re: Nested List
Ultra Talker

Posts: 316
Trades: 0
Might as well use tables then
Joe3000 is offline
Reply With Quote
View Public Profile
 
Old 03-28-2007, 02:01 PM Re: Nested List
LadynRed's Avatar
Defies a Status

Posts: 10,017
Location: Tennessee
Trades: 0
Using a &nbsp; is ok if you only need 1 space. A string of them would just not be practical and that's why margins and/or padding would be a better solution .
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Nested List
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 1.01510 seconds with 13 queries