PDA

View Full Version : Website search bar


brummy1984
01-17-2011, 02:34 AM
Hi guys, I have recently added a search bar to my website (www.computeradviser.co.uk), the problem is that when I search for something it takes me to the google home page without any search results

<form id="searchform" action="http://www.google.com/search" method="get">

<div>
<h2>Site Search</h2>
<input type="hidden" value="www.computeradviser.co.uk" name="sitesearch"/>
<input id="s" size="15" type="text" value="Search this site" alt="search"/>
<input id="x" type="submit" title="Search computeradviser.co.uk" value="Search">
</div>
</form>


any help would be gratefull

Matt

Robert
01-17-2011, 04:09 AM
Two things I've noticed off the bat:

1) There's no name attribute for your search box
2) I believe (not 100% though) that the text box's name needs to be Q not S (not that it matters completely, since there's no name attribute yet anyway...)