Microsoft Windows: A thirty-two bit extension and graphical shell to a sixteen-bit patch to an eight-bit operating system originally coded for a four-bit microprocessor which was written by a two-bit company that can't stand one bit of competition
Hoe heb je die toewijzing toegewezen dan?
ik heb zelf een wrapper object geschreven voor het xmlhttprequest object. daarbij geef ik bij de constructor een functie mee die dient als statehandler. die functie wijs ik als volgt toe in de constructor:
JavaScript:
1
2
3
| //HTTPRequest is het xmlhttprequest object //fStateHandler is de referentie naar de functie this.HTTPRequest.onreadystatechange = fStateHandler |
Microsoft Windows: A thirty-two bit extension and graphical shell to a sixteen-bit patch to an eight-bit operating system originally coded for a four-bit microprocessor which was written by a two-bit company that can't stand one bit of competition
Sommige browsers resetten inderdaad ook onreadystatechange als de open() method wordt uitgevoerd. Ik meen dat dat in voorgaande versies van de XMLHttpRequest specificatie (WD) ook zo was opgenomen, maar in de laatste versie lijkt het erop dat onreadystatechange wel behouden moet blijven.tombo_inc schreef op dinsdag 10 juli 2007 @ 11:42:
[...]
ik vroeg mij dus af waarom na een httprequest de onstatechange eventhandler weer gereset wordt. ik vind dit tamelijk vervelend namelijk, want je moet zo iedere keer weer die eventhandler toewijzen.
Het is dus afwachten wanneer de verschillende browservendors zich gaan confirmeren aan deze standaard...
Intentionally left blank
ok dat wilde ik even weten
voorlopig moet je dus even controleren of de eventhandler behouden blijft of niet, en indien nodig dus opnieuw toewijzen.
bedankt
voorlopig moet je dus even controleren of de eventhandler behouden blijft of niet, en indien nodig dus opnieuw toewijzen.
bedankt
Microsoft Windows: A thirty-two bit extension and graphical shell to a sixteen-bit patch to an eight-bit operating system originally coded for a four-bit microprocessor which was written by a two-bit company that can't stand one bit of competition