Cmd property

A

Andy Dingley

It was somewhere outside Barstow when Todd Cary
I came across this tag and it has a CMD property.

That's a tag with a cmd attribute. Please use the correct names for
things, because once you start to delve deep, then it begins to
matter.
My HTML book
(O'Reilly) does not list such a tag.

There's a time to outgrow such books. One of the great things about
the net is that the exact documents that define it are publically
available, either as RFCs (the network) or as TRs (for web things).
Learn to read "DTD"s like this one
http://www.w3.org/TR/html4/sgml/dtd.html
_This_ is the authoritative reference for HTML (or at least one
version of HTML). Go to the source, not to a book (which is often
itself wrong or outdated).
Is this a special extension?
<div class=Bar id=BarExit menu="Menu_CASES"
cmd="HTTP://10.0.1.27/php/search.php">

Yes. These are less common than they used to be in the mid 90's, but
they still pop up.

At a guess, there's some JavaScript on the page that installs itself
as a menu handler and uses these "menu" and "cmd" attributes to
control its behaviour.

This isn't a bad approach. It works and it won't break anything. But
it _does_ mean that the HTML is no longer strictly valid. This may or
(probably) may not be a problem for you. I'd continue to use such
code, but I don't think I'd do it from scratch.
 
T

Todd Cary

Andy said:
It was somewhere outside Barstow when Todd Cary



That's a tag with a cmd attribute. Please use the correct names for
things, because once you start to delve deep, then it begins to
matter.




There's a time to outgrow such books. One of the great things about
the net is that the exact documents that define it are publically
available, either as RFCs (the network) or as TRs (for web things).
Learn to read "DTD"s like this one
http://www.w3.org/TR/html4/sgml/dtd.html
_This_ is the authoritative reference for HTML (or at least one
version of HTML). Go to the source, not to a book (which is often
itself wrong or outdated).




Yes. These are less common than they used to be in the mid 90's, but
they still pop up.

At a guess, there's some JavaScript on the page that installs itself
as a menu handler and uses these "menu" and "cmd" attributes to
control its behaviour.

This isn't a bad approach. It works and it won't break anything. But
it _does_ mean that the HTML is no longer strictly valid. This may or
(probably) may not be a problem for you. I'd continue to use such
code, but I don't think I'd do it from scratch.
Thank you for the detailed explanation. Greatly appreciated.

Todd
 
D

David Dorward

Richard said:
It would appear to be an obsolete tag so newer browsers won't recognize
it.
It was a valid tag

It isn't a tag, its an attribute.
in html 1.0

There is no such thing. The first formal version of HTML was 2.0 (defined in
RFC 1866).
but is not listed in valid tags with 4.0.

There is no cmd attribute in any version of HTML published by the W3C, nor
does it exist in RFC 1866. The <div> _tag_ on the other hand is perfectly
standard.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,764
Messages
2,569,566
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top