<!-- If user stop while the ActiveX loading, this part is called -->
AND HERE I WANT TO CALL JAVASCRIPT FUNCTION, IE:
<script>load_failed();</script>
</OBJECT>
But it looks like, tha javascript is not working inside of the object tag. I want this javascript function to be called automatically, without any user input.
Does anybody know how to do it ?
Thanks for any help.
Originally posted by Dave Clark
[B]You still have this problem with confusing what is "valid" with what is considered according to "standards":
No the problem is that you don't understand that if it's not in the SPEC it's not HTML, becuse the "standards" defines what is HTML.
The problem isn't that you offer people help and provide them with invalid code that works in some browsers, the problem is that you don TELL people that your solution consists of proprietary code.
Note. Authors of HTML documents are advised that changes are likely to occur in the realm of intrinsic events (e.g., how scripts are bound to events). Research in this realm is carried on by members of the W3C Document Object Model Working Group (see the W3C Web Site at http://www.w3.org/ for more information).
Just because their committee cannot decide to recommend an event handler (even one that has been in use for years, like "onError") does not constitute using it a sin.
Netscape has supported the following events since JavaScript 1.0 (asterisks indicate included in W3C recommendation):
A lot of the ones that W3C does not include in their recommendation have to do with window objects. In fact, they do not enter the window object realm at all. They are only interested in the document (and perhaps rightly so).
Just because their committee cannot decide to recommend an event handler (even one that has been in use for years, like "onError") does not constitute using it a sin.
There is nothing preventing you from using event handlers that is not in the HTML spec... but DONT't put them in the HTML... keep them in the javascript where they belong.
The point here is that there is a right way to do it (that will give you valid code) and a wrong way (generally prefered by clark).
Even the very MS documentation page he links to shows how to add eg onerror the right way, he just likes to break the specs for the hell of it.
If it works (and it does -- as testified to by the person I helped), then it is valid
Many authors rely on a limited set of browsers to check on the documents they produce, assuming that if the browsers can render their documents they are valid. Unfortunately, this is a very ineffective means of verifying a document's validity precisely because browsers are designed to cope with invalid documents by rendering them as well as they can to avoid frustrating users.
In other words, you're saying your code is valid because it works in a program whose first assumption is that you don't know what you're doing.
Hi all,
I hope someone will be able to help we this problem:
Basically, what I want to do is to call a javascript function in the <OBJECT> tag, when the ActiveX content of this tag failed to load.
That means:
<OBJECT CLASSID="some-class-id" ODEBASE="some-codebase">
<PARAM name="some-param" value="some-value">
<!-- If user stop while the ActiveX loading, this part is called -->
AND HERE I WANT TO CALL JAVASCRIPT FUNCTION, IE:
<script>load_failed();</script>
</OBJECT>
But it looks like, tha javascript is not working inside of the object tag. I want this javascript function to be called automatically, without any user input.
Does anybody know how to do it ?
Thanks for any help.
Marek
My workin java script
<script type="text/javascript">
function menuOn(e, color) {
if ( ! color ) {
color = 'green';
}
e.style.backgroundColor=color;
e.style.opacity='.50';
e.style.filter='alpha(opacity=50)';
e.style.border = '1px solid black';
}
function menuOff(e) {
e.style.opacity = 0;
e.style.filter = 'alpha(opacity=0)';
}</script>
Bookmarks