facebook

How to get the response data from form submit

  1. MobiOne Archive
  2.  > 
  3. Getting Help – General
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #334996 Reply

    donij
    Member

    Hi Wayne/Octavio,

    I have a form which submits its content to a url. The server processed the request and responds with a string.

    Q1. How do I get this response so I can process it further.
    Q2. I submit the form using Get and observed that there is always an extra value at the end of my content
    like &_=34545565…. What does this extra string represent or mean.

    Thanks

    #335019 Reply

    Hi donij,

    >Q1. How do I get this response so I can process it further.
    You could set your design as a Form and manage data retrieved with postSubmitForm_m1 functions added in custom.js file.
    This example should be helpful for you: http://www.genuitec.com/support-genuitec/viewtopic.php?f=14&t=2846

    >Q2. I submit the form using Get and observed that there is always an extra value at the end of my content
    like &_=34545565…. What does this extra string represent or mean.
    That parameter looks like a jsonp callback name… are you using jsonp to interact with your web service?

    #335025 Reply

    donij
    Member

    Hi Octavio,

    A1. I have tried the pre and postSubmit function and they don’t get called. Also am using ASP.Net IHttpHandler for my context.response.write(“Test response”) to return response from the url.

    A2. I didn’t use any jsonp. I only set my form to submit to a url and set the form result type to Data-text(AJAX).

    Thanks.

    #335026 Reply

    donij
    Member

    Ok! I can now process the response from server now. The pre and postsubmit function are responding. I actually duplicated them not knowing that mobi automatically generate them.

    Still waiting for clarification on the extra string attached to the Get submit data.

    Thanks

    #335028 Reply

    support-michael
    Keymaster

    @donij

    >Still waiting for clarification on the extra string attached to the Get submit data.

    I have no idea what that parameter is atm and never seen it before other than something similar in jsonp requests. The submit processing uses the jquery.ajax() function to perform the request. The exact code is in phoneui.js submitForm() I think.

    #335036 Reply

    donij
    Member

    Ok.. I will investigate further. Thanks.

Viewing 6 posts - 1 through 6 (of 6 total)
Reply To: How to get the response data from form submit

You must be logged in to post in the forum log in