I want to convert the following prototype js to jquery js.
Can anyone help me please?
Thanks in advance.
window.onload = function () {
new Ajax.Autocompleter("function_name", "autocomplete_choices",
base_url+"application/ajaxsearch/", {});
$('function_search_form').onsubmit = function () {
inline_results();
return false;
}
}
function inline_results() {
new Ajax.Updater ('function_description',
base_url+'application/ajaxsearch',
{method:'post', postBody:'description=true&function_name='+$F('function_name')});
new Effect.Appear('function_description');
}
HTML is the following
<form id="function_search_form" method="post"
action="http://127.0.0.1/ci_sample/index.php/application/search">
<div>
<label for="function_name">Search by function name </label>
<input type="text" name="function_name" id="function_name" />
<input type="submit" value="search" id="search_button" />
<div id="autocomplete_choices" class="autocomplete"></div>
</div>
</form>