Randy said:
So, forms don't have attributes?
They have attributes in the natural language sense, including width, height
color and so on. They do not have attributes in the markup language sense,
this applies for _`form' elements_. The difference is important as it does
not need a `form' element to render a form.
[...]
Probably you mean `form control'.
As someone whose native language is not English, you should at least
understand the short comings of peoples grasp (or lack thereof) the
differences in the way people describe things.
Bad wording often indicates cluelessness that is tried to be covered by
buzzwords picked up somewhere and used unreflected. It certainly does
in this case (example: `determine if it was a field or a tag'), and so
it was commented on it. Reasonable readers would think about that and
get themselves informed in the process.
Whether innerText is "appropriate" or not is totally and 100% directly
related to its context of use.
And what "Web Standard" standardized getElementByID?
W3C DOM Level 1 and W3C DOM Level 2 do.
Since you are nitpicking the wording, I will too. Its not a "Web
Standard", its an ECMA standard.
1. ECMAScript (ECMA-262) is an ECMA standard which was developed from
JavaScript and JScript which were intended primarily for Web use, both
client-side and server-side. It can be included in the list of Web
standards that exist nowadays.
2. It's about the DOM, not the programming language, a difference that you
still are either not willing or unable to comprehend although it has been
explained to you several times.
The Web itself has no "Standard",
Yes, it has _standards_. DOM Level 1 and 2 are two of them.
I, too, thought before that W3C specifications are not standards,
however the W3C (now?) makes it quite clear that their specifications/
Recommendations can be considered Web standards since they are created
using a standardization process:
<
http://www.w3.org/Consortium/>
This is also how their work is percepted among many other participants
than you.
it has standards writing bodies that attempt to write standards for
the Web.
They don't attempt to do it, they just do it. Note that these bodies have
members that are other organizations involved in building and maintaining
the Web. And the W3C, as one of the bodies mentioned, requires their
standards to have, among other conditions, at least two interoperable
implementations before it becomes a Recommendation (that is why, e.g., CSS
2.1 is after more than a year still only a Candidate Recommendation), so
it is not all just theory as you appear to suggest.
For a site, such as that one, to be taken seriously, you should at least
invest some of that §2 in a decent web server setup so that you do not
have unprofessional popups and ads all over it.
Yes, now you have to get personal, for you have from little to no valid
arguments. Some of the dirt you are throwing at me is somehow going to
stay on my clothes, yes? No, in fact you are throwing dirt at yourself
instead. I'd pity you if I had time for it.
But JFYI, as you are this interested in my well-being: Plans to move to
another server which would no longer require frames domain redirection
and so no more mandatory ads (that I don't like either), and yet be non-
expensive (actually, it would be EUR 0 plus remote root access

) are
already underway and should be completed within the next month. It was
planned to be completed by now but both timing and legal issues have
forced me to postpone it by another three weeks. I am still posting the
domain-related URIs since the URIs redirected to will become inaccessible
in the future as I will not have means for automated redirection for them
(the account will just be canceled in time by the responsible admin).
However, alas I am not so sure that you manage to understand that.
Non-function properties are not called (as methods are), they are
accessed.
Maybe you are looking for this:
// don't use document.get...By...() if you don't have to
var objectReference = document.forms[...].elements["name"];
And if the form or element doesn't exist?
If the referenced object does not exist, the code will fail. It has
intentionally been left as an exercise to the reader to complete the
feature test using the example given. This group is intended as a
discussion medium, not as a source for complete solutions.
Or, it exists outside a form?
That is a valid possibility, yet not a likely one. The OP would have to
use proprietary objects and DOM Level 2 methods then. I recommend against
that; making the element a descendant element of a `form' element is less
painful as the resulting DOM subtree can be accessed by both standardized
and downwards compatible references.
[...]
If you are going to rant about minor issues such as what people call
things, and then post code to "correct" them and include code to do
object/method detection, you could at least apply the same nit-picking
to your own code.
See above. And please, get a life.
PointedEars