sign in | join about | help | sitemap
Connecting Tech Pros Worldwide
Adrienne's Avatar

Possibly OT - would like to have an element back


Question posted by: Adrienne (Guest) on July 24th, 2005 12:58 AM
The elements MENU and DIR were in the HTML 2.0 spec, and disappeared in
4. I would like to have them back, they makes sense.

For example:
<menu>
<li>Home</li>
<li>Contact</li>
</menu>

Perhaps speech enabled user agents could react accordingly, perhaps say
"Navigation", which would differentiate it from an ordinary list, like a
list of groceries [1]:
<ul>
<li>Milk</li>
<li>Bread</li>
<li>Eggs</li>
<li>Bacon</li>
</ul>

Search engines could probably benefit as well since they would know right
away where to start crawling. Probably make external stylesheets a
little easier, I know a lot of people use <div id="menu"><ul>..., so it
might make an author's life a little less complicated.

I realize I can use these elements with a transitional Doctype, but I
prefer Strict.

Just my thoughts.

[1] I would also like to be able to use the caption element inside a ul,
eg:
<ul>
<caption>Laundry List</caption>
<li>Soap</li>
</ul>

--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share
8 Answers Posted
kchayka's Avatar
Guest - n/a Posts
#2: Re: Possibly OT - would like to have an element back

Adrienne wrote:[color=blue]
>
> I would also like to be able to use the caption element inside a ul,
> eg:
> <ul>
> <caption>Laundry List</caption>[/color]

Caption is one element that has potential for multiple uses. Image
captions come to mind right off. Too bad the specs limit it to tables.

--
Reply email address is a bottomless spam bucket.
Please reply to the group so everyone can share.
Lachlan Hunt's Avatar
Guest - n/a Posts
#3: Re: Possibly OT - would like to have an element back

Adrienne wrote:[color=blue]
> <menu>
> <li>Home</li>
> <li>Contact</li>
> </menu>[/color]

See <nl>...
[color=blue]
> <ul>
> <caption>Laundry List</caption>
> <li>Soap</li>
> </ul>[/color]

....and <label> in the current XHTML 2.0 draft.

http://www.w3.org/TR/xhtml2/mod-list.html#s_listmodule

--
Lachlan Hunt
http://lachy.id.au/
http://GetFirefox.com/ Rediscover the Web
http://GetThunderbird.com/ Reclaim your Inbox
Jukka K. Korpela's Avatar
Jukka K. Korpela July 24th, 2005 12:58 AM
Guest - n/a Posts
#4: Re: Possibly OT - would like to have an element back

Adrienne <arbpen2003@sbcglobal.net> wrote:
[color=blue]
> The elements MENU and DIR were in the HTML 2.0 spec, and disappeared in
> 4.[/color]

They didn't. They are still allowed in HTML 4.01 Transitional (and
XHTML 1.0 Transitional).

They were never implemented properly. Browsers mostly treat MENU and DIR as
synonyms for UL.
[color=blue]
> I would like to have them back, they makes sense.[/color]

They won't come back. Whether they make sense in principle is debatable, but
the debate is futile. In fact, even the distinction between <ul> and <ol>
could be regarded as presentational.
[color=blue]
> <menu>
> <li>Home</li>
> <li>Contact</li>
> </menu>
>
> Perhaps speech enabled user agents could react accordingly, perhaps say
> "Navigation", which would differentiate it from an ordinary list,[/color]

Why? There are no links there. And if you make the content of each <li>
element a link, why can't a browser recognize this simple structure and deal
with it differently, if appropriate?

The XHTML 2.0 drafts contain <nl> for you, in the nice tradition of using
obscure element names and unnecessarily making markup-level differences
between different types of lists. (Using an _attribute_ to indicate the type
of a list might be reasonable.)
[color=blue]
> Search engines could probably benefit as well since they would know right
> away where to start crawling.[/color]

No, they just look for links.
[color=blue]
> I know a lot of people use <div id="menu"><ul>...,[/color]

A lot of people use <div class="heading2"> as well, or worse still
<p class="heading2">. There will always be a possibility to use wrong markup.
People can use <ul class="menu"> and then specify a compact, menu-like
presentation if they like.
[color=blue]
> [1] I would also like to be able to use the caption element inside a ul,
> eg:
> <ul>
> <caption>Laundry List</caption>
> <li>Soap</li>
> </ul>[/color]

An old and natural idea, but in fact you can use

<div class="lh">Laundry List</div>
<ul class="with-lh">
<caption>Laundry List</caption>
<li>Soap</li>
</ul>

with a suitable style sheet. (Classing the <ul> helps in making its top
margin small or zero so that the list visually connects to its list heading.)

Or maybe with <hN>Laundry List</hN> with a suitable integer in place of N.

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html

Adrienne's Avatar
Guest - n/a Posts
#5: Re: Possibly OT - would like to have an element back

Gazing into my crystal ball I observed Lachlan Hunt
<spam.my.gspot@gmail.com> writing in news:424602db$0$7764$5a62ac22@per-qv1-
newsreader-01.iinet.net.au:
[color=blue]
> Adrienne wrote:[color=green]
>> <menu>
>> <li>Home</li>
>> <li>Contact</li>
>> </menu>[/color]
>
> See <nl>...
>[color=green]
>> <ul>
>> <caption>Laundry List</caption> <li>Soap</li> </ul>[/color]
>
> ...and <label> in the current XHTML 2.0 draft.
>
> http://www.w3.org/TR/xhtml2/mod-list.html#s_listmodule
>[/color]

Yes! I like it. Just what I was looking for.

--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share
Tim's Avatar
Guest - n/a Posts
#6: Re: Possibly OT - would like to have an element back

Adrienne <arbpen2003@sbcglobal.net> wrote:
[color=blue][color=green]
>> Search engines could probably benefit as well since they would know right
>> away where to start crawling.[/color][/color]

"Jukka K. Korpela" <jkorpela@cs.tut.fi> posted:
[color=blue]
> No, they just look for links.[/color]

The one advantage I could see could be search engines not using the page's
navigational array in the summary it provides about a website. It's just
as bad as the number of sites described as; this website requires Internet
Explorer, etc.
[color=blue][color=green]
>> [1] I would also like to be able to use the caption element inside a ul,
>> eg:
>> <ul>
>> <caption>Laundry List</caption>
>> <li>Soap</li>
>> </ul>[/color]
>
> An old and natural idea, but in fact you can use
>
> <div class="lh">Laundry List</div>
> <ul class="with-lh">
> <caption>Laundry List</caption>
> <li>Soap</li>
> </ul>
>
> with a suitable style sheet. (Classing the <ul> helps in making its top
> margin small or zero so that the list visually connects to its list heading.)[/color]

Which is essentially what they said, but with added classes. However,
don't the DTD preclude everything but LI elements being directly inside UL
and OL elements?

--
If you insist on e-mailing me, use the reply-to address (it's real but
temporary). But please reply to the group, like you're supposed to.

This message was sent without a virus, please delete some files yourself.
Jukka K. Korpela's Avatar
Jukka K. Korpela July 24th, 2005 12:58 AM
Guest - n/a Posts
#7: Re: Possibly OT - would like to have an element back

Tim <tim@mail.localhost.invalid> wrote:
[color=blue]
> The one advantage I could see could be search engines not using the
> page's navigational array in the summary it provides about a website.[/color]

I guess that's what the W3C's working group thinks too. Indeed indexing
robots could skip <nl> elements in some contexts. But it's really an attempt
at an ad hoc solution. What if an author thinks that a table (a real, genuine
structure of tabulated data) is more suitable for use as a navigational
collection of links?

Besides, if HTML is being rewritten and made incompatible with existing HTML
user agents on purpose, why stick to the idea of making navigation lists part
of the content. Use <link>, Luke. Advanced browsers already support it.
Of course it could be made more structural, but then the most important thing
is to define the link types well (the rel="..." values).
[color=blue]
> It's just as bad as the number of sites described as; this website
> requires Internet Explorer, etc.[/color]

You can avoid such nonsense either by not including a navigational collection
of links on every page or by making it the last element on the page,
optionally positioning it visually wherever you want.
[color=blue][color=green]
>> <div class="lh">Laundry List</div>
>> <ul class="with-lh">
>> <caption>Laundry List</caption> <li>Soap</li> </ul>
>>
>> with a suitable style sheet. (Classing the <ul> helps in making its top
>> margin small or zero so that the list visually connects to its list
>> heading.)[/color]
>
> Which is essentially what they said, but with added classes. However,
> don't the DTD preclude everything but LI elements being directly inside
> UL and OL elements?[/color]

It does. Sorry for the I confusion I caused, when I failed to remove
the <caption> element from my suggestion. My point was that instead of the
currently hypothetical <caption>, you can make the list's caption an element
before the list. Perhaps as a heading, e.g.

<h2 class="lh">Laundry List</h2>
<ul class="with-lh">
<li>Soap</li>
...
</ul>

Classes are a clumsy way, but they work - as opposite to XHTML 2.0, which has
been planned for years, still exists as an incomplete draft, and would become
useable on the Web only after defined _and_ implemented in browsers _and_
after sufficiently many people have upgraded their browsers (to something
that currently doesn't exist even on a designer's desk).

--
Yucca, http://www.cs.tut.fi/~jkorpela/
Pages about Web authoring: http://www.cs.tut.fi/~jkorpela/www.html

Tim's Avatar
Guest - n/a Posts
#8: Re: Possibly OT - would like to have an element back

Tim wrote:
[color=blue][color=green]
>> It's just as bad as the number of sites described as; this website
>> requires Internet Explorer, etc.[/color][/color]

"Jukka K. Korpela" <jkorpela@cs.tut.fi> posted:
[color=blue]
> You can avoid such nonsense either by not including a navigational collection
> of links on every page or by making it the last element on the page,[/color]

I do, I just wish other's would... ;-)
[color=blue]
> optionally positioning it visually wherever you want.[/color]

Unfortunately this doesn't quite work as well as we'd like. For instance,
I certainly can't think of a simple and robust way of writing a
navagational array at the end of the page, but displaying it at the top,
and not getting it messed up with the other content that's there.

Even using simple float right and lefts with sidebars can be a bit iffy,
too. Even worse with MSIE messing things up.

--
If you insist on e-mailing me, use the reply-to address (it's real but
temporary). But please reply to the group, like you're supposed to.

This message was sent without a virus, please delete some files yourself.
Lauri Raittila's Avatar
Lauri Raittila July 24th, 2005 01:00 AM
Guest - n/a Posts
#9: Re: Possibly OT - would like to have an element back

in comp.infosystems.www.authoring.html, Tim wrote:
[color=blue]
> Unfortunately this doesn't quite work as well as we'd like. For instance,
> I certainly can't think of a simple and robust way of writing a
> navagational array at the end of the page, but displaying it at the top,
> and not getting it messed up with the other content that's there.[/color]

Menu at
http://www.student.oulu.fi/~laurirai/www/
Should work.

Complex (positioning the navigation menu to top *and* left)
http://www.student.oulu.fi/~laurirai/www/css/splitmenu/
(breaks when user overrides line-height. But without footer, works
nicely.)

--
Lauri Raittila <http://www.iki.fi/lr> <http://www.iki.fi/zwak/fonts>
Utrecht, NL.
 
Not the answer you were looking for? Post your question . . .
196,815 members ready to help you find a solution.
Join Bytes.com

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 196,815 network members.
Post your question now . . .
It's fast and it's free

Popular Articles

Top Community Contributors