DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 4 of 4

Thread: Ajax POST request using ASP.net

  1. #1
    Join Date
    Mar 2006
    Posts
    100

    Ajax POST request using ASP.net

    Ok guys here is the skinny,

    I am trying to use a "servlet" ASP.net page and post data to it using the xmlHTTPRequest object. Once I post to it how can I access the post parameters?

    example:

    Lets say this is my Javascript call
    try
    {
    xmlHTTPSes=GetXmlHttpObject();
    if (xmlHTTPSes == null)
    {
    alert ("Your browser does not support the XMLHttpRequest object. Please upgrade to a newer browser.");
    return;
    }
    queryString="mode=changeValue";
    xmlHTTPSes.onreadystatechange=responseSesVar;
    xmlHTTPSes.open("POST","servlet.aspx",true);
    xmlHTTPSes.setRequestHeader("Content-Type","application/x-www-form-urlencoded");
    xmlHTTPSes.send(queryString);
    }
    catch(e){alert(e.message());}

    And I want to retrieve the mode value.

    Thanks
    "America... just a nation of two hundred million used car salesmen with all the money we need to buy guns and no qualms about killing anybody else in the world who tries to make us uncomfortable. " - Hunter S. Thompson

    MCAD
    IBM Business Partner

  2. #2
    Join Date
    Nov 2003
    Location
    Portland, OR
    Posts
    8,387
    Request.Form("mode")
    Phil Weber
    http://www.philweber.com

    Please post questions to the forums, where others may benefit.
    I do not offer free assistance by e-mail. Thank you!

  3. #3
    Join Date
    Mar 2006
    Posts
    100
    n/m got it I can use request.params
    "America... just a nation of two hundred million used car salesmen with all the money we need to buy guns and no qualms about killing anybody else in the world who tries to make us uncomfortable. " - Hunter S. Thompson

    MCAD
    IBM Business Partner

  4. #4
    Join Date
    Mar 2006
    Posts
    100
    Oh haha yeah got it thanks
    "America... just a nation of two hundred million used car salesmen with all the money we need to buy guns and no qualms about killing anybody else in the world who tries to make us uncomfortable. " - Hunter S. Thompson

    MCAD
    IBM Business Partner

Similar Threads

  1. Replies: 3
    Last Post: 09-12-2006, 02:31 AM
  2. New forum + some AJAX links
    By Lori in forum AJAX
    Replies: 0
    Last Post: 02-09-2006, 02:26 PM
  3. Xindice query
    By nonolap in forum XML
    Replies: 0
    Last Post: 05-26-2005, 04:10 AM
  4. Free ASP.NET Web Matrix Design/Editor Tool Released
    By ASPSmith Training in forum dotnet.announcements
    Replies: 0
    Last Post: 06-18-2002, 03:39 AM
  5. Soap-Cannot POST request to .asp file
    By Itsu in forum Enterprise
    Replies: 0
    Last Post: 01-29-2001, 04:49 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center