I was wondering is there any possible way that I can have a webview that automatically inputs the values for text boxes on a website and submit so that the user can just bypass the search (in particular search forms) entirely? So the user is only shown the result?
An example is : http://www.eatwellguide.org/mobile/
I noticed looking at the source it is using javascript.
Is there anyway I can automatically fill those in and press submit without the user even seeing this page. So, the webpage loads up to the results page?
Thanks in advance!
In response to the answer:
Is there any specific place I have to put this code? I put it after I did a load request to the webView for the site I listed above and then after the [super viewDidLoad], I put in the code you listed with values for first value and second value, with nameofOneInput being ‘SearchKeyword’, ‘SearchSubmit’ being the 2nd, and then the form id as ‘frmsAS’? It’s still not working. What am I doing wrong? I actually tried it to execute when the a button is pressed, still did not work
Yes, you can use the following javascript to fill out the form then submit it.
You obviously have to set
firstValueandsecondValuefirst.