Jump to content

Drop Down Change Form Action - Multiple Search Engines


Nootpad

Recommended Posts

Hello,

 

I need a cross-browser solution for using the select tag to facilitate switching between search engines.

 

I've created & populated several different Google Custom Engines and need to enable a select (dropdown) form to search each one as wanted.

 

Here's a working form for one of the engines:

<form name="form1" action="/search_results1.php" id="searchbox_000728331164281115855:5ctdneheiqs" onSubmit="return checkform(this);">
<input type="hidden" name="cx" value="000728331164281115855:5ctdneheiqs">
<input type="hidden" name="cof" value="FORID:11">
<select name="as_qdr" class="selecttime">
<option value="all">anytime</option>
<option value="d">past 24 hours</option>
<option value="w">past week</option>
<option value="m">past month</option>
<option value="y">past year</option>
</select><input class="input" type="text" name="q" size="38" value="">
<input type="image" name="sa" src="images/0044.gif" class="imgbtn">
</form>

The above code has several common attributes (3 of them unique) shared by the other engines:

 

1) each has a unique results page (eg the action=)

 

2) the id="searchbox_000728331164281115855:5ctdneheiqs"

 

3) the name "cx" with a value="000728331164281115855:5ctdneheiqs"

 

4) <input type="hidden" name="cof" value="FORID:11">

 

 

There are three unique, defining attributes for each individual search form - the action, cx value and the searchbox id are different for each engine.

 

1) the URL of the results page(s)

 

2) the <input type="hidden" name="cx" value="000728331164281115855:5ctdneheiqs">

 

3) id="searchbox_000728331164281115855:5ctdneheiqs"

 

 

Any help would be most appreciated; I've been all over the Web including Google's CSE groups, etc. for weeks to no avail.

 

 

# # #

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.