Question

I have a form like follows:

<form action="" method="GET" data-ronsor-url="http://web-search.tk">
<input id="q">
<input type="submit" value="search">
</form>

But nothing is submitted. if the form was at http://web-search.tk/?q=mysearch, when the form is submitted, the url is http://web-search.tk/?, why is this. It worked before.

Note: I will delete this question if I get more than 1 downvotes

Was it helpful?

Solution 2

Try adding a name attribute to the form input:

<form action="" method="GET" data-ronsor-url="http://web-search.tk">
    <input id="q" name="q">
    <input type="submit" value="search">
</form>

I am not quite sure what are you trying to achieve but if you set the action attr = http://web-search.tk it performs the search at http://web-search.tk website.

You might be depending on some js if you wish to perform the search at your website, but again I'm not quite sure what's yor goal!

Good luck, hope it helps

OTHER TIPS

You need to specify the form action and the name of the input (query) field (instead of, or in addition to, the id):

<form action="http://web-search.tk" method="GET">
<input name="q">
<input type="submit" value="search">
</form>
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top