Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Ajax in synchronous mode note working in Tomcat

 
Ravi Majety
Ranch Hand
Posts: 59
Eclipse IDE Java Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Friends,

Actually i am developing an application where i need to get the values using ajax in synchronous mode. But it is working fine in JBOSS where as it is failed in Tomcat. when i changed it to asynchronous mode, it is working fine...but i want it in synchronous mode. Please give me an solution..

 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You're not really giving us any information: please TellTheDetails, and remember that ItDoesntWorkIsUseless!
 
Abimaran Kugathasan
Ranch Hand
Posts: 2066
Clojure IntelliJ IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And KeepItDown!
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65223
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I removed the all uppercase subject. Please don't do that.
 
Ravi Majety
Ranch Hand
Posts: 59
Eclipse IDE Java Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Friends..

Actually the code is as follows...




Actually the AJAX can be used either in Synchronous mode or asynchronous mode....but i want it in synchronous mode. because based on value from xmllHttp.responseText the page submission depends...

If i used in asynchronous mode (making third parameter in xmlHttp.open to true) then flag is considered as false and remaining code is getting executed and page is never submitted...

The above code is a part of my actual page. It worked fine in my JBOSS Application Server, But when i shifted to Tomcat Application Server , some times it is working fine and sometimes it was not.
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Your flag value check is in the wrong place.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic