I use only onsubmit even in that just refresh the grid that i have, But i don't know the reason for page reloading
Here's my Form Action
<form id="fff" onsubmit="return get_Search()">
Here is my Search Button
<li><a href="#" class="srch" onclick="get_Search()"></a></li>
My On Click Event
$j( "#PrsNo" ).keypress(function( event ) {
if ( event.which == 13 ) {
get_Search();
}
});
And this is my Fuction :
function get_Search()
{
// alert('enter');
var PrsNo = $("#PrsNo").val();
var PrsRequestedBy = $("#PrsRequestedBy ").val();
var PrsDepartment = $("#PrsDepartment").val();
var PrsTheme = $("#PrsTheme").val();
var PrsMerchandiserName = $("#PrsMerchandiserName").val();
var SentDate = $("#SentDate").val();
var PrsStatus = $("#PrsStatus").val();
// alert(PrsNo);
$j('#flex1').flexOptions({newp:1, params:[{name:'searchtype', value: '1'},{name:'prsno', value: PrsNo},{name:'prsreqby',value:PrsRequestedBy},{name:'prsdepar',value:PrsDepartment},{name:'prstheme',value:PrsTheme},{name:'prsmername', value: PrsMerchandiserName},{name:'prssentdate', value: SentDate},{name:'pstatus',value:PrsStatus}]});
$j("#flex1").flexReload();
}
But i dont' know the reason why my page is reloading when i press enter or click on the search icon.
What might be the reason, I shall provide my full code if required
Here is my Controller