I wonder if this is related to a bug that was fixed in firefox 3.0.6...
https://bugzilla.mozilla.org/show_bug.cgi?id=444322
"Firefox 3 onload and DOMContentLoaded event firing before the page is
fully loaded"
We experienced that problem with Firefox 3.0.5 made a work around for
it, and then 3.0.6 arrived and fixed it
But there is another bug mentioned in comment #72
https://bugzilla.mozilla.org/show_bug.cgi?id=444322#c72 which might be
similar to this problem (even mentions using an alert will cause the
problem to appear)
Brill Pappin wrote:
Addendum to my last:
Apparently the simple alert case *is* working in Safari 3.2.1 but *is
not* in Firefox 3.0.6.
This suggests to me that the script has not been updated for Firefox,
or that firefox just doesn't support the script (which I find hard to
believe).
is anyone else using this method of capturing onLoad events?
- Brill
On 21-Feb-09, at 2:14 PM, Brill Pappin wrote:
I have a panel with which I'm implementing IHeaderContributor and
the following code:
....
@Override
public void renderHead(IHeaderResponse response) {
response.renderOnLoadJavascript("alert('test')");
}
...
which output in the HTML:
...
<script type="text/javascript" src="../../resources/
org.apache.wicket.markup.html.WicketEventReference/wicket-
event.js"></script>
<script type="text/javascript" ><!--/*--><![CDATA[/*><!--*/
Wicket.Event.add(window, "load", function(event) { alert('test');});
/*-->]]>*/</script>
...
However no matter what I seem to do (i've tried this about six
different way so far) the alert *never* fires (note: my actual
script is more complex, but I'm using alert to debug).
I've also tried it in both Safari 3.2.1 and Firefox 3.0.6 with the
same result (i.e. nothing happens)
Is there a known bug in 1.4-SNAPSHOT?
Does anyone else have this working?
- Brill
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
--
Jason Lea