P
Pugi!
Currently I am using a responsexml for an xmlhttprequest. The
information is then processed by javascript : elements are created with
attributes incl events using setAttribute; in other words I create html
with the information in the responsexml. This works fine with firefox
and Opera, but IE doesn't do anything with these events (onclick,
onmouseover, ...) on an image or cell (td) created this way. One
alternative is that I should be able to identify the elements who need
a specific event and then launch a javascript function that adds the
desired event to the tags.
for (var i = 0; i < arrElements.length; i++) {
arrElements.onclick = doSomething;
}
The other alternative is that instead of xml I created text (html) on
the serverside and use a responsetext.
I think the second one is the best alternative ?
Or are there other options ?
Pugi!
information is then processed by javascript : elements are created with
attributes incl events using setAttribute; in other words I create html
with the information in the responsexml. This works fine with firefox
and Opera, but IE doesn't do anything with these events (onclick,
onmouseover, ...) on an image or cell (td) created this way. One
alternative is that I should be able to identify the elements who need
a specific event and then launch a javascript function that adds the
desired event to the tags.
for (var i = 0; i < arrElements.length; i++) {
arrElements.onclick = doSomething;
}
The other alternative is that instead of xml I created text (html) on
the serverside and use a responsetext.
I think the second one is the best alternative ?
Or are there other options ?
Pugi!