add: debug("cqAutoSave: " + theQuery); 
context: function cqAutoSave(n) {    // use incremental updates if autosave form element is set    // and the incremental flag is true (has already been exported)    var theFlag = document.getElementById(g_cq_autosave_id);    //alert("cqAutoSave: " + theFlag.checked);    if (theFlag.checked) {        if (! g_cq_autosave_incremental) {            // this session hasn't been exported, as far as we know:            // export it, then mark it ok for incremental            cqExport(document.getElementById(g_cq_query_form));            g_cq_autosave_incremental = true;        } else {            //alert("cqAutoSave: incremental");            var theForm = document.getElementById(g_cq_query_form);            var theUri = document.getElementById(g_cq_uri).value;            if (theForm && theUri) {                // default to current buffer                if ( (!n) && (n != 0) )                    n = g_cq_buffer_current;                var theQuery =                    'xdmp:node-replace((doc("' + theUri + '")/'                    // path to buffer n                    + g_cq_buffers_id + '/'                    // XPath starts at 1, not 0                    + g_cq_buffer_basename + ')[' + (1+n) + "],\n"                    // new value                    + '<' + g_cq_buffer_basename + '>'                    + escape(getBuffer(n).value)                    + '</' + g_cq_buffer_basename + '>'                    + '), "updated"';                //alert("cqAutoSave: " + theQuery);                submitForm(theForm, theQuery, "text/html");            } // theForm and theUri        } // if incremental    } // if autosave} // cqAutoSave
meta: 952	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/952/469474651c3f770b832f583fd47778d445b5bf5a/cq.js/buggy/cq.js