Hi,
I have a acroform, which is embedded in an iframe like the example below:
The acromform has some text fields and a submit button, which submits (POST) to a server script (j2ee servlet in my case). The response content type can only be PDF/FDF type.
I want to redirect to another landing page giving some info to the user AFTER the user has hit the submit button and got the response back from the servlet.
Basically once the request-response cycle has been completed for the acroform submit.
To accomplish this, i send a PDF content type response to the form submit , which has the below javascript:
app.launchURL("http://www.infopage.com/infopage",false);
On Firefox this opens the URL in a new tab. For IE it opens in the same window.
Is there a browser independent way to accomplish this feat, from within the embeded reader in the browser?
Is there a way to identify whether the form submit from the browser embeded pdf or from a offline pdf reader, not within the browser.
I notice that the User-agent header of the submit request has
user-agent:Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.5) Gecko/2008120122 Firefox/3.0.5
in case of firefox embeded PDF submit. in case of offline viewer, i get
user-agent:AcroForms
is this a reliable way to solve the "request coming from" issue.
OR i should look into iframe events and all those DHTML/AJAX thingy to deal with this.
Please help!! I am stuck with this for a long time now!!
Thanks,
Subhro.
George