HTML Google Search
Platform: Javascript
Published Dec 27, 2009
Updated Dec 27, 2009
First of all. This is JAVASCRIPT, this will not work on Wordpress! So, users can input search parameters (EG. Script Codes) then it would redirect the current page to google then search the inputed text.
I am working on a website where i post scripts called
ScriptFreak
you can download a zip or see the preview (Under /Scripts/Google Search Box)
Enjoy!
<html>
<body>
<script type="text/javascript">
function google()
{
var str=document.getElementById('googlebox').value;
str="http://www.google.com/search?hl=en&source=hp&q=" + str + "&aq=f&oq=&aqi=";
var replaced=str.replace(" ","+");
window.location.replace(replaced)
}
</script>
<input type="text" value="Google" id="googlebox"/>
<input type="button" value="Go" onclick="google()"/>
</body>
</html>