No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
6 Posted Topics
The best way would be to make an ajax call, but the proposed iframe solution would work as well. You don't even have to make the iframe small, just set it's style attribute to: [code] style="visibility: hidden" [/code]
This solution is not really a sleep. It effectively postpones the execution of function called by the setTimeout method, but javasctipy is asynchronous, so the execution of the commands following the setTimeout method will happend immediately after. After a couple of google queries I found the only solution to sleep …
There are more ways to do it than just cookies - it basicaly depends if you want to store the session between visits that happend at the same time, or if you want to save sessions for later use. If the later is what you want, go for cookies: [code] …
It is perfectly ok what compiler regards, but I agree it is not a good coding style.
Your problem is, that the subsequent calls to the ajaxrequest are using the same global variable for the request. The posted answer is right in the point to make the calls synchronous. Other thing you can do is to use namespacing and nested functions to create new httprequest object for …
What makes a difference between ajax and iframe approach is the use of dom model. Ajax takes this as one of it's base concepts. This same goes for the original question - use dom to add/remove the elements you would like to display: [code] var input=document.createElement("input"); input.setAttribute("type","text"); ..... [/code]
The End.
nemo5