tags:

views:

28

answers:

1

Hi all. I want to know how to implement a search in my grid with jquery. I construct the grid. The form of search display when i press the search button in the left below of grid. How to implement to post the data and to implement the search in server side. Please help me

A: 

you can for example download demo files from http://www.trirand.com/blog/?page_id=6. There are files search.php and search_adv.php inside. The file search_adv.php is an example for "advance seraching" and search.php for the "simple searching". On the demo page http://trirand.com/blog/jqgrid/jqgrid.html you can select "New in version 3.5" and "Advanced Searching". The file search_adv.php corresponds to the backend part of this example.

Oleg
Ok thanks but i work in a framework php. the grid is OK . i create a button and when i click it , display the search form . but when i click find in search form the data doesn't send to the controller . I think that is the url???How can i correct it any idea? here is my code :$("#search").click(function(){ jQuery("#list").jqGrid('searchGrid', { sopt:['cn','bw','eq','ne','lt','gt','ew'], url:"http://url.local/gc/kerko", } ); });
eni
Probably you should only have no errors in your code: `url:"http://url.local/gc/kerko", }` should be replaced to `url:"http://url.local/gc/kerko" }` (no ',' before '}'). Also look at the "Integrations" / "Live Data Manipulation" code from the demo page http://trirand.com/blog/jqgrid/jqgrid.html
Oleg