On Wed, 16 Jun 2004 21:14:50 +0100, Tom <tom.RemoveThis@digital-haze.com> wrote:
> Hi
> I have the following scenario
>
> <ul>
> <li>Mainlist1</li>
> <ul>
> <li>Sublist 1</li>
> <li>Sublist 2</li>
> <li>Sublist 3</li>
> <li>Sublist 4</li>
> </ul>
> <li>Mainlist 2</li>
> <li>Mainlist 3</li>
> </ul>
>
> What do I have to do to make this validate as XHTML? I would be
> surprised if
> you could not have sub lists in some format....
> Thanks
You can't have a <ul> directly within another <ul>
Instead, make your nested list one of the list items:
<ul>
<li>Mainlist1
<ul>
<li>Sublist 1</li>
<li>Sublist 2</li>
<li>Sublist 3</li>
<li>Sublist 4</li>
</ul>
</li>
<li>Mainlist 2</li>
<li>Mainlist 3</li>
</ul>
Not only is this correct XHTML, but it makes sure the first sublist is
associated with the first Mainlist list item. eg. they are both within
the same <li> tag.
Grey
--
The technical axiom that nothing is impossible sinisterly implies the
pitfall corollary that nothing is ridiculous.
- <a style='text-decoration: underline;' href="http://www.greywyvern.com/webslavent.php?msg=53" target="_blank">http://www.greywyvern.com/webslavent.php?msg=53</a> - Support the Opera
Puffin Mascot Campaign!<!-- ~MESSAGE_AFTER~ -->
>> Stay informed about: valid sublists?