$(function(){
var lastSel;
jQuery(“#grid-customers”).jqGrid({
url:'php.scripts/get.customers.json.php',
datatype: 'json',
mtype: 'POST',
colNames:['idcustomers','firstname', 'lastname','address1','address2','city','state','zip','phone','email','cell'],
colModel :[
{name:'idcustomers', index:'idcustomers', width:55, jsonmap: 'idcustomers'},
{name:'firstname', index:'firstname', width:90, editable: true, jsonmap: 'firstname'},
{name:'lastname', index:'lastname', width:90, editable: true, jsonmap: 'lastname'},
{name:'address1', index:'address1', width:90, editable: true, jsonmap: 'address1'},
{name:'address2', index:'address2', width:90, editable: true, jsonmap: 'address2'},
{name:'city', index:'city', width:90, editable: true, jsonmap: 'city'},
{name:'state', index:'state', width:90, editable: true, jsonmap: 'state'},
{name:'zip', index:'zip', width:90, editable: true, jsonmap: 'zip'},
{name:'phone', index:'phone', width:90, editable: true, jsonmap: 'phone'},
{name:'email', index:'email', width:90, editable: true, jsonmap: 'email'},
{name:'cell', index:'cell', width:90, editable: true, jsonmap: 'cell'}
],
pager: '#grid-customers-pager',
rowNum:100,
rowList:[100,200,300],
sortname: 'idcustomers',
sortorder: 'desc',
viewrecords: true,
gridview: true,
caption: 'Customers',
height: 375,
width: 1200,
editurl: 'php.scripts/update.row.php',
ajaxGridOptions: {type:”POST”}
}).navGrid('#grid-customers-pager',{ edit: false, add: true }, {}, {}, {}, {}, {}).inlineNav(“#grid-customers-pager”,{});
jQuery(“#grid-customers”).jqGrid('filterToolbar',{autoSearch: true});
});