I have been reading a lot about CSS menus, and made a few for myself.
What is the advantage of using <ul> and <li> tags rather than <p> tags for horizontal menus? Is this because the <ul> tag acts as a container?
From a markup standpoint without CSS, it seems to make more sense to use the <p> tag so that the menu is actually horizontal, especially if one were has a "A-Z" type menu.
Just curious. . . Thanks
horizontal menus / <ul> versus <p> question
its more about semantics. A menu is usually an un-ordered list of links, so it makes sense to use the html markup for lists - <ul> <li>. In so doing you will have all the necessary elements to style your list.
<ul id='menu'>
<li><a href='#'>link</a></li>
...
</ul>
#menu {...}
#menu li {...}
#menu a {...}
#menu a:hover {...}
Using a <p> will surely work. As will using <a> with a style of display:block. Although both of these will almost certainly require an aditional container to properly target styles at the menu elements.
horizontal menus / <ul> versus <p> question
Thanks for the reply Chris S. -- Semantics are a good enough reason for me. Seems like <ul> tags can save headaches the more complicated the menus are.

