On Dec 23, 2009, at 2:29 AM, RobG wrote:
On Dec 22, 10:51 pm, Schalk Neethling <volume4.sch...@gmail.com>
wrote:
Hi there,
I was wondering whether anyone knows if the jQuery website has some
sort
of API to access the search functionality of the site?
Stimulus, response...
<form action="">
<div>
<input type="text" name="queryText" value="events">
<input type="button" value="Search..." onclick="
searchDocs(this.form.queryText);
">
</div>
</form>
<script type="text/javascript">
function searchDocs(el) {
document.location =
'http://docs.jquery.com/Special:Search?ns0=1&search='
+ encodeURIComponent(el.value)
+ '&go=';
}
</script>
interesting that you would put an onclick on the input rather than an
onsubmit on the form. any particular reason for that?
--Karl
____________
Karl Swedberg
www.englishrules.com
www.learningjquery.com