I have a jqgrid with data loading from an xml stream (handled by django 1.1.1):
jQuery(document).ready(function(){
jQuery(\"#list\").jqGrid({
url:\'/do
It seems to me you should replace
postData:{
site:1,
date_start:document.getElementById('datepicker_start').value,
date_end:document.getElementById('datepicker_end').value
},
with
postData:{
site:1,
date_start: function() { return document.getElementById('datepicker_start').value; },
date_end: function() { return document.getElementById('datepicker_end').value;}
},
UPDATED:
In your current solution the value of postData are calculated one time as you create jqGrid. In the postData with functions jqGrid forward postData to jQuery.ajax and during every jQuery.ajax (after $("#list").trigger("reloadGrid");) the values from datepicker will be read at the moment of jQuery.ajax call.