Click to See Complete Forum and Search --> : assigning different actions to radio button when combined with searching


muggzy
04-15-2006, 06:24 AM
hi people,

im trying to get two radio buttons to search two different sites when clicked and a search term entered. check out the example here http://designfunky.com/project/newtest.html

the code i have for the amazon button is

Code:

<form action="http://www.amazon.co.uk/gp/associates/link-types/searchbox.html" method="get" name="search" target="_top"> <input type="hidden" name="tag" value="designfunky-21" /> <input type="hidden" name="creative" value="7034" /> <input type="hidden" name="campaign" value="1878" /> <input type="hidden" name="mode" value="blended" /> <input type="hidden" name="adid" value="1P0BJZD1S76QAZCQ884J"> <img src="images/amazon.gif" width="169" height="50" /> <p align="left"> <input id="keyword" name="keyword" type="text" size="50" /> <input id="button" type="submit" value="Search" name="Submit" alt="[Go]" /> </form>

and for the stock exchange one

Code:

<form id="search_form" method="get" action="http://www.sxc.hu/browse.phtml"> <p><img src="images/stock_xchng.gif" width="169" height="50" /> <input type="hidden" name="f" value="search" /> <p> <input name="txt" type="text" class="search" size="50" /> <input name="submit" type="submit" value="Search" src="img/btn_search.gif" /> <input type="hidden" name="w" value="1"> </form>

any idea how i assign this to each button? is it html or does it creep into PHP?

any help would be really appreciated.

geraelindsey
04-16-2006, 10:40 PM
The link http://designfunky.com/project/newtest.html is not working.

ray326
04-17-2006, 12:47 PM
Not enough to go on yet but one thing is for sure, a radio button should not cause an action like a form submission.