Replace deprecated javascript escape() with encodeURIComponent()
authorPasi Kallinen <pasi.kallinen@pttk.fi>
Fri, 28 Jun 2013 05:47:11 +0000 (08:47 +0300)
committerDan Scott <dscott@laurentian.ca>
Fri, 17 Jan 2014 01:40:23 +0000 (20:40 -0500)
Signed-off-by: Pasi Kallinen <pasi.kallinen@pttk.fi>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
Conflicts:
Open-ILS/xul/staff_client/chrome/content/auth/controller.js
Open-ILS/xul/staff_client/chrome/content/util/error.js
Open-ILS/xul/staff_client/chrome/content/util/print.js
Open-ILS/xul/staff_client/server/admin/offline_manage_xacts.js
Open-ILS/xul/staff_client/server/circ/print_list_template_editor.js

Signed-off-by: Dan Scott <dscott@laurentian.ca>
36 files changed:
Open-ILS/web/js/dojo/openils/BibTemplate.js
Open-ILS/web/js/dojo/openils/XUL.js
Open-ILS/web/js/ui/default/acq/common/li_table.js
Open-ILS/web/js/ui/default/conify/global/config/z3950_source.js
Open-ILS/web/js/ui/default/conify/global/vandelay/import_bib_trash_group.js
Open-ILS/web/opac/common/js/dtree.js
Open-ILS/web/opac/skin/default/js/result_common.js
Open-ILS/xul/staff_client/chrome/content/OpenILS/util_overlay_chrome.xul
Open-ILS/xul/staff_client/chrome/content/OpenILS/util_overlay_offline.xul
Open-ILS/xul/staff_client/chrome/content/cat/opac.js
Open-ILS/xul/staff_client/chrome/content/main/main.js
Open-ILS/xul/staff_client/chrome/content/main/menu.js
Open-ILS/xul/staff_client/chrome/content/util/error.js
Open-ILS/xul/staff_client/chrome/content/util/list.js
Open-ILS/xul/staff_client/chrome/content/util/network.js
Open-ILS/xul/staff_client/server/OpenILS/util_overlay.xul
Open-ILS/xul/staff_client/server/admin/offline_manage_xacts.js
Open-ILS/xul/staff_client/server/cat/bucketz39_dialog.js
Open-ILS/xul/staff_client/server/cat/copy_browser.js
Open-ILS/xul/staff_client/server/cat/copy_editor.js
Open-ILS/xul/staff_client/server/cat/record_buckets.js
Open-ILS/xul/staff_client/server/cat/spine_labels.js
Open-ILS/xul/staff_client/server/cat/util.js
Open-ILS/xul/staff_client/server/cat/z3950.js
Open-ILS/xul/staff_client/server/circ/circ_brief.xul
Open-ILS/xul/staff_client/server/circ/copy_status.js
Open-ILS/xul/staff_client/server/circ/util.js
Open-ILS/xul/staff_client/server/patron/barcode_entry.xul
Open-ILS/xul/staff_client/server/patron/display.js
Open-ILS/xul/staff_client/server/patron/holds.js
Open-ILS/xul/staff_client/server/patron/info_group.js
Open-ILS/xul/staff_client/server/patron/items.js
Open-ILS/xul/staff_client/server/serial/manage_dists.js
Open-ILS/xul/staff_client/server/serial/manage_subs.js
Open-ILS/xul/staff_client/server/serial/sdist_editor.js
Open-ILS/xul/staff_client/server/serial/sitem_editor.js

index 8c81447..180b228 100644 (file)
@@ -109,7 +109,7 @@ if(!dojo._hasResource["openils.BibTemplate"]) {
 
                                 // Do pre-query stuff
                                 dojo.forEach(pre_query_callbacks, function (cb) {
-                                    try { (new Function( 'BT', 'slotXML', 'slot', unescape(cb.innerHTML) ))(BT,bib,slot) } catch (e) {/*meh*/}
+                                    try { (new Function( 'BT', 'slotXML', 'slot', decodeURIComponent(cb.innerHTML) ))(BT,bib,slot) } catch (e) {/*meh*/}
                                 });
 
                                 var query = slot.getAttribute('query');
@@ -130,14 +130,14 @@ if(!dojo._hasResource["openils.BibTemplate"]) {
 
                                 // Do post-query stuff
                                 dojo.forEach(post_query_callbacks, function (cb) {
-                                    try { (new Function( 'item_list', 'BT', 'slotXML', 'slot', unescape(cb.innerHTML) ))(item_list,BT,bib,slot) } catch (e) {/*meh*/}
+                                    try { (new Function( 'item_list', 'BT', 'slotXML', 'slot', decodeURIComponent(cb.innerHTML) ))(item_list,BT,bib,slot) } catch (e) {/*meh*/}
                                 });
 
                                 if (!item_list.length) return;
 
                                 // Do pre-render stuff
                                 dojo.forEach(pre_render_callbacks, function (cb) {
-                                    try { (new Function( 'item_list', 'BT', 'slotXML', 'slot', unescape(cb.innerHTML) ))(item_list,BT,bib,slot) } catch (e) {/*meh*/}
+                                    try { (new Function( 'item_list', 'BT', 'slotXML', 'slot', decodeURIComponent(cb.innerHTML) ))(item_list,BT,bib,slot) } catch (e) {/*meh*/}
                                 });
 
                                 var templated = slot.getAttribute('templated') == 'true';
@@ -152,7 +152,7 @@ if(!dojo._hasResource["openils.BibTemplate"]) {
                                         slot
                                     ).orphan().forEach(function(x) {
                                         var name = x.getAttribute('name');
-                                        var value = (new Function( 'item_list', 'BT', 'slotXML', 'slot', unescape(x.innerHTML) ))(item_list,BT,bib,slot);
+                                        var value = (new Function( 'item_list', 'BT', 'slotXML', 'slot', decodeURIComponent(x.innerHTML) ))(item_list,BT,bib,slot);
                                         if (name && (value || value == '')) {
                                             template_values[name] = value;
                                             template_value_count++;
@@ -164,7 +164,7 @@ if(!dojo._hasResource["openils.BibTemplate"]) {
                                         dojo.attr(
                                             slot, "innerHTML",
                                             dojo.string.substitute(
-                                                unescape(slot.innerHTML),
+                                                decodeURIComponent(slot.innerHTML),
                                                 template_values
                                             )
                                         );
@@ -188,7 +188,7 @@ if(!dojo._hasResource["openils.BibTemplate"]) {
 
                                 // Do post-render stuff
                                 dojo.forEach(post_render_callbacks, function (cb) {
-                                    try { (new Function( 'item_list', 'BT', 'slotXML', 'slot', unescape(cb.innerHTML) ))(item_list,BT,bib,slot) } catch (e) {/*meh*/}
+                                    try { (new Function( 'item_list', 'BT', 'slotXML', 'slot', decodeURIComponent(cb.innerHTML) ))(item_list,BT,bib,slot) } catch (e) {/*meh*/}
                                 });
 
                             } catch (e) {
index 656c055..b13b96d 100644 (file)
@@ -55,7 +55,7 @@ if(!dojo._hasResource["openils.XUL"]) {
 
         if (wrap_in_browser) {
             var urls = xulG.urls || window.urls;
-            loc = urls.XUL_BROWSER + "?url=" + window.escape(loc);
+            loc = urls.XUL_BROWSER + "?url=" + window.encodeURIComponent(loc);
             content_params = dojo.mixin(
                 {
                     "no_xulG": false, "show_print_button": true,
index 9344ad9..b462eed 100644 (file)
@@ -3543,7 +3543,7 @@ function AcqLiTable() {
         );
 
         win = window.open(
-            oilsBasePath + '/acq/lineitem/findbib?query=' + escape(query),
+            oilsBasePath + '/acq/lineitem/findbib?query=' + encodeURIComponent(query),
             '', 'resizable,scrollbars=1,chrome');
 
         win.window.recordFound = function(bibId) { 
index c73bc9c..bb191c3 100644 (file)
@@ -55,7 +55,7 @@ function applyCreds(clear) {
 }
 
 function formatSourceName(val) {
-    return '<a href="' + location.href + '/' + escape(val) + '">' + val + '</a>';
+    return '<a href="' + location.href + '/' + encodeURIComponent(val) + '">' + val + '</a>';
 }
 
 var cloneSourceSelector;
index 1cd2bec..93d4264 100644 (file)
@@ -26,7 +26,7 @@ function init2(grp) {
 
 function format_grp(val) {
     return '<a href="' + location.href + 
-        '/' + escape(val) + '">' + val + '</a>';
+        '/' + encodeURIComponent(val) + '">' + val + '</a>';
 }
 
 openils.Util.addOnLoad(init);
index 8f95cb0..974f5de 100644 (file)
@@ -271,7 +271,7 @@ dTree.prototype.clearCookie = function() {
 
 dTree.prototype.setCookie = function(cookieName, cookieValue, expires, path, domain, secure) {
        document.cookie =
-               escape(cookieName) + '=' + escape(cookieValue)
+               encodeURIComponent(cookieName) + '=' + encodeURIComponent(cookieValue)
                + (expires ? '; expires=' + expires.toGMTString() : '')
                + (path ? '; path=' + path : '')
                + (domain ? '; domain=' + domain : '')
@@ -280,12 +280,12 @@ dTree.prototype.setCookie = function(cookieName, cookieValue, expires, path, dom
 
 dTree.prototype.getCookie = function(cookieName) {
        var cookieValue = '';
-       var posName = document.cookie.indexOf(escape(cookieName) + '=');
+       var posName = document.cookie.indexOf(encodeURIComponent(cookieName) + '=');
        if (posName != -1) {
-               var posValue = posName + (escape(cookieName) + '=').length;
+               var posValue = posName + (encodeURIComponent(cookieName) + '=').length;
                var endPos = document.cookie.indexOf(';', posValue);
-               if (endPos != -1) cookieValue = unescape(document.cookie.substring(posValue, endPos));
-               else cookieValue = unescape(document.cookie.substring(posValue));
+               if (endPos != -1) cookieValue = decodeURIComponent(document.cookie.substring(posValue, endPos));
+               else cookieValue = decodeURIComponent(document.cookie.substring(posValue));
        }
        return (cookieValue);
 };
index 061bf6f..c3d4764 100644 (file)
@@ -825,7 +825,7 @@ function fetchGoogleBooksLink () {
         scriptElement.setAttribute("id", "jsonScript");
         scriptElement.setAttribute("src",
             "https://www.googleapis.com/books/v1/volumes?q=" +
-            escape('isbn:' + isbnList.join(' | isbn:')) + "&callback=unhideGoogleBooksLink");
+            encodeURIComponent('isbn:' + isbnList.join(' | isbn:')) + "&callback=unhideGoogleBooksLink");
         scriptElement.setAttribute("type", "text/javascript");
         // make the request to Google Book Search
         document.documentElement.firstChild.appendChild(scriptElement);
index 0860a6d..ce1a778 100644 (file)
@@ -70,7 +70,7 @@
             <label value="Debug:" />
             <textbox id="debug_tb" flex="1"/>
             <button label="Execute" oncommand="try { var dtb = document.getElementById('debug_tb'); alert( eval( dtb.value ) ); } catch(E) { alert(E); }; dtb.focus();"/>
-            <button label="Inspect" oncommand="try { var dtb = document.getElementById('debug_tb'); var dx = eval( dtb.value ); var ds = ''; for (var di in dx) { ds += di + '=' + dx[di] + '\r\n'; }; window.open('data:text/plain;charset=UTF-8,'+window.escape(ds),'debug_win','chrome,resizable,modal'); } catch(E) { alert(E); }; dtb.focus();"/>
+            <button label="Inspect" oncommand="try { var dtb = document.getElementById('debug_tb'); var dx = eval( dtb.value ); var ds = ''; for (var di in dx) { ds += di + '=' + dx[di] + '\r\n'; }; window.open('data:text/plain;charset=UTF-8,'+window.encodeURIComponent(ds),'debug_win','chrome,resizable,modal'); } catch(E) { alert(E); }; dtb.focus();"/>
             <button label="js2JSON" oncommand="try { var dtb = document.getElementById('debug_tb'); alert( js2JSON( eval( dtb.value ) ) ); } catch(E) { alert(E); }; dtb.focus();"/>
         </hbox>
         <keyset><key id="debug_box_key" keycode="VK_F7" modifiers="control,shift" oncommand="JSAN.use('OpenILS.data'); var data = new OpenILS.data(); data.init({'via':'stash'}); var dtb = document.getElementById('debug_tb'); var dx = document.getElementById('debug_box'); if(data.enable_debug || !dx.hidden) { dx.hidden = !dx.hidden; if(!dx.hidden) dtb.focus();}"/></keyset>
index a9dc1d8..10b0f5a 100644 (file)
@@ -65,7 +65,7 @@
             <label value="Debug:" />
             <textbox id="debug_tb" flex="1"/>
             <button label="Execute" oncommand="try { var dtb = document.getElementById('debug_tb'); alert( eval( dtb.value ) ); } catch(E) { alert(E); }; dtb.focus();"/>
-            <button label="Inspect" oncommand="try { var dtb = document.getElementById('debug_tb'); var dx = eval( dtb.value ); var ds = ''; for (var di in dx) { ds += di + '=' + dx[di] + '\r\n'; }; window.open('data:text/plain;charset=UTF-8,'+window.escape(ds),'debug_win','chrome,resizable,modal'); } catch(E) { alert(E); }; dtb.focus();"/>
+            <button label="Inspect" oncommand="try { var dtb = document.getElementById('debug_tb'); var dx = eval( dtb.value ); var ds = ''; for (var di in dx) { ds += di + '=' + dx[di] + '\r\n'; }; window.open('data:text/plain;charset=UTF-8,'+window.encodeURIComponent(ds),'debug_win','chrome,resizable,modal'); } catch(E) { alert(E); }; dtb.focus();"/>
             <button label="js2JSON" oncommand="try { var dtb = document.getElementById('debug_tb'); alert( js2JSON( eval( dtb.value ) ) ); } catch(E) { alert(E); }; dtb.focus();"/>
         </hbox>
         <keyset><key id="debug_box_key" keycode="VK_F7" modifiers="control,shift" oncommand="JSAN.use('OpenILS.data'); var data = new OpenILS.data(); data.init({'via':'stash'}); var dtb = document.getElementById('debug_tb'); var dx = document.getElementById('debug_box'); if(data.debug_build || data.enable_debug || !dx.hidden) { dx.hidden = !dx.hidden; if(!dx.hidden) dtb.focus();}"/></keyset>
index a9b9f5a..1d76bc2 100644 (file)
@@ -89,7 +89,7 @@ function opac_wrapper_set_help_context() {
 }
 
 function set_brief_view() {
-    var url = xulG.url_prefix( 'XUL_BIB_BRIEF?docid=' ) + window.escape(docid); 
+    var url = xulG.url_prefix( 'XUL_BIB_BRIEF?docid=' ) + window.encodeURIComponent(docid);
     dump('spawning ' + url + '\n');
 
     var content_params = {
@@ -119,10 +119,10 @@ function set_brief_view() {
 function set_marc_view() {
     g.view = 'marc_view';
     if (marc_view_reset) {
-        bottom_pane.reset_iframe( xulG.url_prefix( 'XUL_MARC_VIEW?docid=' ) + window.escape(docid),{},xulG);
+        bottom_pane.reset_iframe( xulG.url_prefix( 'XUL_MARC_VIEW?docid=' ) + window.encodeURIComponent(docid),{},xulG);
         marc_view_reset = false;
     } else {
-        bottom_pane.set_iframe( xulG.url_prefix( 'XUL_MARC_VIEW?docid=' ) + window.escape(docid),{},xulG);
+        bottom_pane.set_iframe( xulG.url_prefix( 'XUL_MARC_VIEW?docid=' ) + window.encodeURIComponent(docid),{},xulG);
     }
     opac_wrapper_set_help_context(); 
     bottom_pane.get_contentWindow().addEventListener('load',opac_wrapper_set_help_context,false);
@@ -292,10 +292,10 @@ function set_marc_edit() {
 function set_copy_browser() {
     g.view = 'copy_browser';
     if (copy_browser_reset) {
-        bottom_pane.reset_iframe( xulG.url_prefix( 'XUL_COPY_VOLUME_BROWSE?docid=' ) + window.escape(docid),{},xulG);
+        bottom_pane.reset_iframe( xulG.url_prefix( 'XUL_COPY_VOLUME_BROWSE?docid=' ) + window.encodeURIComponent(docid),{},xulG);
         copy_browser_reset =false;
     } else {
-        bottom_pane.set_iframe( xulG.url_prefix( 'XUL_COPY_VOLUME_BROWSE?docid=' ) + window.escape(docid),{},xulG);
+        bottom_pane.set_iframe( xulG.url_prefix( 'XUL_COPY_VOLUME_BROWSE?docid=' ) + window.encodeURIComponent(docid),{},xulG);
     }
     opac_wrapper_set_help_context(); 
     bottom_pane.get_contentWindow().addEventListener('load',opac_wrapper_set_help_context,false);
@@ -304,10 +304,10 @@ function set_copy_browser() {
 function set_hold_browser() {
     g.view = 'hold_browser';
     if (hold_browser_reset) {
-        bottom_pane.reset_iframe( xulG.url_prefix( 'XUL_HOLDS_BROWSER?docid=' ) + window.escape(docid),{},xulG);
+        bottom_pane.reset_iframe( xulG.url_prefix( 'XUL_HOLDS_BROWSER?docid=' ) + window.encodeURIComponent(docid),{},xulG);
         hold_browser_reset = false;
     } else {
-        bottom_pane.set_iframe( xulG.url_prefix( 'XUL_HOLDS_BROWSER?docid=' ) + window.escape(docid),{},xulG);
+        bottom_pane.set_iframe( xulG.url_prefix( 'XUL_HOLDS_BROWSER?docid=' ) + window.encodeURIComponent(docid),{},xulG);
     }
     opac_wrapper_set_help_context(); 
     bottom_pane.get_contentWindow().addEventListener('load',opac_wrapper_set_help_context,false);
@@ -332,7 +332,7 @@ function open_acq_orders() {
             "get_barcode_and_settings"
         ].forEach(function(k) { content_params[k] = xulG[k]; });
 
-        var loc = urls.XUL_BROWSER + "?url=" + window.escape(
+        var loc = urls.XUL_BROWSER + "?url=" + window.encodeURIComponent(
             xulG.url_prefix("ACQ_LINEITEM") +
             docid + "?target=bib"
         );
@@ -370,7 +370,7 @@ function open_alt_serial_mgmt() {
             "get_barcode_and_settings"
         ].forEach(function(k) { content_params[k] = xulG[k]; });
 
-        var loc = urls.XUL_BROWSER + "?url=" + window.escape(
+        var loc = urls.XUL_BROWSER + "?url=" + window.encodeURIComponent(
             xulG.url_prefix("SERIAL_LIST_SUBSCRIPTION?record_entry=") +
             docid
         );
@@ -643,10 +643,10 @@ xulG.reload_opac = function() {
 function set_serctrl_view() {
     g.view = 'serctrl_view';
     if (serctrl_view_reset) {
-        bottom_pane.reset_iframe( xulG.url_prefix( 'XUL_SERIAL_SERCTRL_MAIN?docid=' ) + window.escape(docid), {}, xulG);
+        bottom_pane.reset_iframe( xulG.url_prefix( 'XUL_SERIAL_SERCTRL_MAIN?docid=' ) + window.encodeURIComponent(docid), {}, xulG);
         serctrl_view_reset =false;
     } else {
-        bottom_pane.set_iframe( xulG.url_prefix( 'XUL_SERIAL_SERCTRL_MAIN?docid=' ) + window.escape(docid), {}, xulG);
+        bottom_pane.set_iframe( xulG.url_prefix( 'XUL_SERIAL_SERCTRL_MAIN?docid=' ) + window.encodeURIComponent(docid), {}, xulG);
     }
 }
 
@@ -809,7 +809,7 @@ function batch_receive_in_new_tab() {
 
         xulG.new_tab(
             xulG.url_prefix('XUL_SERIAL_BATCH_RECEIVE?docid=') +
-                window.escape(docid), {
+                window.encodeURIComponent(docid), {
                 "tab_name": $("offlineStrings").getString(
                     "menu.cmd_serial_batch_receive.tab"
                 )
@@ -821,7 +821,7 @@ function batch_receive_in_new_tab() {
 }
 
 function remove_me() {
-    var url = xulG.url_prefix( 'XUL_BIB_BRIEF?docid=' ) + window.escape(docid);
+    var url = xulG.url_prefix( 'XUL_BIB_BRIEF?docid=' ) + window.encodeURIComponent(docid);
     dump('removing ' + url + '\n');
     try { top_pane.remove_iframe( url ); } catch(E) { dump(E + '\n'); }
     $('nav').setAttribute('hidden','true');
@@ -1084,7 +1084,7 @@ function add_volumes() {
 function manage_parts() {
     try {
         g.view = 'manage_parts';
-        var loc = urls.XUL_BROWSER + "?url=" + window.escape(
+        var loc = urls.XUL_BROWSER + "?url=" + window.encodeURIComponent(
             window.xulG.url_prefix('CONIFY_MANAGE_PARTS?r=') + docid
         );
         if (manage_parts_reset) {
index a86b642..1886dec 100644 (file)
@@ -108,7 +108,7 @@ opentabs:
                         if(urls[firstURL]) {
                             firstURL = urls[firstURL];
                         }
-                        firstURL = '&firstURL=' + window.escape(firstURL);
+                        firstURL = '&firstURL=' + window.encodeURIComponent(firstURL);
                     }
                     else {
                         firstURL = '';
@@ -118,7 +118,7 @@ opentabs:
                     firstURL = '';
                 }
                 targetwindow = xulG.window.open(urls.XUL_MENU_FRAME
-                    + '?server='+window.escape(G.data.server) + firstURL,
+                    + '?server='+window.encodeURIComponent(G.data.server) + firstURL,
                     '_blank','chrome,resizable'
                 );
                 targetwindow.xulG = xulG;
index 4d923c2..3addc9c 100644 (file)
@@ -152,7 +152,7 @@ main.menu.prototype = {
             label = offlineStrings.getString(labelKey);
 
             // URL
-            var loc = urls.XUL_BROWSER + '?url=' + window.escape( obj.url_prefix('CONIFY/') + path + '.html');
+            var loc = urls.XUL_BROWSER + '?url=' + window.encodeURIComponent( obj.url_prefix('CONIFY/') + path + '.html');
 
             obj.command_tab(
                 event,
@@ -169,8 +169,8 @@ main.menu.prototype = {
             label = offlineStrings.getString(labelKey);
 
             // URL
-            var loc = urls.XUL_BROWSER + '?url=' + window.escape( obj.url_prefix('XUL_LOCAL_ADMIN_BASE/') + path);
-            if(addSes) loc += window.escape('?ses=' + ses());
+            var loc = urls.XUL_BROWSER + '?url=' + window.encodeURIComponent( obj.url_prefix('XUL_LOCAL_ADMIN_BASE/') + path);
+            if(addSes) loc += window.encodeURIComponent('?ses=' + ses());
 
             obj.command_tab( 
                 event,
@@ -188,7 +188,7 @@ main.menu.prototype = {
             var label = offlineStrings.getString(labelKey);
 
             // URL
-            var loc = urls.XUL_BROWSER + '?url=' + window.escape(obj.url_prefix('EG_WEB_BASE/') + path);
+            var loc = urls.XUL_BROWSER + '?url=' + window.encodeURIComponent(obj.url_prefix('EG_WEB_BASE/') + path);
 
             content_params = content_params || {
                 'no_xulG': false,
@@ -516,9 +516,9 @@ main.menu.prototype = {
                         var param_count = 0;
                         for (var i in p) {
                             if (param_count++ == 0) url += '?'; else url += '&';
-                            url += i + '=' + window.escape(p[i]);
+                            url += i + '=' + window.encodeURIComponent(p[i]);
                         }
-                        var loc = obj.url_prefix('XUL_BROWSER?url=') + window.escape( obj.url_prefix(url) );
+                        var loc = obj.url_prefix('XUL_BROWSER?url=') + window.encodeURIComponent( obj.url_prefix(url) );
                         obj.new_tab(
                             loc, 
                             {}, 
@@ -536,7 +536,7 @@ main.menu.prototype = {
 
                     obj.data.stash_retrieve();
                     var loc = obj.url_prefix('XUL_BROWSER?url=') 
-                        + window.escape( obj.url_prefix('XUL_PATRON_EDIT') );
+                        + window.encodeURIComponent( obj.url_prefix('XUL_PATRON_EDIT') );
                     obj.command_tab(
                         event,
                         loc, 
@@ -617,7 +617,7 @@ main.menu.prototype = {
                 ['oncommand'],
                 function(event) { 
                     obj.data.stash_retrieve();
-                    var loc = urls.XUL_BROWSER + '?url=' + window.escape(
+                    var loc = urls.XUL_BROWSER + '?url=' + window.encodeURIComponent(
                         obj.url_prefix('XUL_HOLD_PULL_LIST')
                     );
                     obj.command_tab(event, loc, {'tab_name' : offlineStrings.getString('menu.cmd_browse_hold_pull_list.tab')} );
@@ -650,9 +650,8 @@ main.menu.prototype = {
             'cmd_local_admin' : [
                 ['oncommand'],
                 function(event) { 
-                    //obj.set_tab(obj.url_prefix('XUL_LOCAL_ADMIN')+'?ses='+window.escape(ses())+'&session='+window.escape(ses()),{},{});
-                    var loc = urls.XUL_BROWSER + '?url=' + window.escape(
-                        obj.url_prefix( 'XUL_LOCAL_ADMIN?ses='+window.escape(ses())+'&session='+window.escape(ses()) )
+                    var loc = urls.XUL_BROWSER + '?url=' + window.encodeURIComponent(
+                        obj.url_prefix( 'XUL_LOCAL_ADMIN?ses='+window.encodeURIComponent(ses())+'&session='+window.encodeURIComponent(ses()) )
                     );
                     obj.command_tab(
                         event,
@@ -677,7 +676,7 @@ main.menu.prototype = {
             'cmd_local_admin_reports' : [
                 ['oncommand'],
                 function(event) { 
-                    var loc = urls.XUL_BROWSER + '?url=' + window.escape( obj.url_prefix('XUL_REPORTS?ses=') + ses());
+                    var loc = urls.XUL_BROWSER + '?url=' + window.encodeURIComponent( obj.url_prefix('XUL_REPORTS?ses=') + ses());
                     obj.command_tab(
                         event,
                         loc, 
@@ -1428,21 +1427,21 @@ main.menu.prototype = {
                 ['oncommand'],
                 function(event) {
                     obj.data.stash_retrieve();
-                    obj.command_tab(event,obj.url_prefix('XUL_STAT_CAT_EDIT?ses=') + window.escape(ses()), {'tab_name' : offlineStrings.getString('menu.cmd_stat_cat_edit.tab')},{});
+                    obj.command_tab(event,obj.url_prefix('XUL_STAT_CAT_EDIT?ses=') + window.encodeURIComponent(ses()), {'tab_name' : offlineStrings.getString('menu.cmd_stat_cat_edit.tab')},{});
                 }
             ],
             'cmd_non_cat_type_edit' : [
                 ['oncommand'],
                 function(event) {
                     obj.data.stash_retrieve();
-                    obj.command_tab(event,obj.url_prefix('XUL_NON_CAT_LABEL_EDIT?ses=') + window.escape(ses()), {'tab_name' : offlineStrings.getString('menu.cmd_non_cat_type_edit.tab')},{});
+                    obj.command_tab(event,obj.url_prefix('XUL_NON_CAT_LABEL_EDIT?ses=') + window.encodeURIComponent(ses()), {'tab_name' : offlineStrings.getString('menu.cmd_non_cat_type_edit.tab')},{});
                 }
             ],
             'cmd_copy_location_edit' : [
                 ['oncommand'],
                 function(event) {
                     obj.data.stash_retrieve();
-                    obj.command_tab(event,obj.url_prefix('XUL_COPY_LOCATION_EDIT?ses=') + window.escape(ses()),{'tab_name' : offlineStrings.getString('menu.cmd_copy_location_edit.tab')},{});
+                    obj.command_tab(event,obj.url_prefix('XUL_COPY_LOCATION_EDIT?ses=') + window.encodeURIComponent(ses()),{'tab_name' : offlineStrings.getString('menu.cmd_copy_location_edit.tab')},{});
                 }
             ],
             'cmd_test' : [
@@ -1457,14 +1456,14 @@ main.menu.prototype = {
                 ['oncommand'],
                 function(event) {
                     obj.data.stash_retrieve();
-                    obj.command_tab(event,obj.url_prefix('TEST_HTML?ses=') + window.escape(ses()),{ 'browser' : true },{});
+                    obj.command_tab(event,obj.url_prefix('TEST_HTML?ses=') + window.encodeURIComponent(ses()),{ 'browser' : true },{});
                 }
             ],
             'cmd_test_xul' : [
                 ['oncommand'],
                 function(event) {
                     obj.data.stash_retrieve();
-                    obj.command_tab(event,obj.url_prefix('TEST_XUL?ses=') + window.escape(ses()),{ 'browser' : false },{});
+                    obj.command_tab(event,obj.url_prefix('TEST_XUL?ses=') + window.encodeURIComponent(ses()),{ 'browser' : false },{});
                 }
             ],
             'cmd_console' : [
@@ -1501,7 +1500,7 @@ main.menu.prototype = {
             'cmd_public_opac' : [
                 ['oncommand'],
                 function(event) {
-                    var loc = urls.XUL_BROWSER + '?url=' + window.escape(
+                    var loc = urls.XUL_BROWSER + '?url=' + window.encodeURIComponent(
                         obj.url_prefix('remote')
                     );
                     obj.command_tab(
index a865349..4523e2d 100644 (file)
@@ -374,7 +374,7 @@ util.error.prototype = {
         JSAN.use('OpenILS.data');
         //var data = new OpenILS.data(); data.init({'via':'stash'});
         //data.temp_yns_xml = xml; data.stash('temp_yns_xml');
-        var url = urls.XUL_FANCY_PROMPT; // + '?xml_in_stash=temp_yns_xml' + '&title=' + window.escape(title);
+        var url = urls.XUL_FANCY_PROMPT;
         if (typeof xulG != 'undefined') if (typeof xulG.url_prefix == 'function') url = xulG.url_prefix( url );
         JSAN.use('util.window'); var win = new util.window();
         var fancy_prompt_data = win.open(
@@ -447,7 +447,7 @@ util.error.prototype = {
         JSAN.use('OpenILS.data');
         //var data = new OpenILS.data(); data.init({'via':'stash'});
         //data.temp_yns_xml = xml; data.stash('temp_yns_xml');
-        var url = urls.XUL_FANCY_PROMPT; // + '?xml_in_stash=temp_yns_xml' + '&title=' + window.escape(title);
+        var url = urls.XUL_FANCY_PROMPT;
         if (typeof xulG != 'undefined') if (typeof xulG.url_prefix == 'function') url = xulG.url_prefix( url );
         JSAN.use('util.window'); var win = new util.window();
         var fancy_prompt_data = win.open(
index d4e5039..0eba98b 100644 (file)
@@ -429,7 +429,7 @@ util.list.prototype = {
                 var col_ordinal = col.getAttribute('ordinal'); 
                 my_cols[ col_id ] = { 'hidden' : col_hidden, 'width' : col_width, 'ordinal' : col_ordinal };
             }
-            JSAN.use('util.file'); var file = new util.file('tree_columns_for_'+window.escape(id));
+            JSAN.use('util.file'); var file = new util.file('tree_columns_for_'+window.encodeURIComponent(id));
             file.set_object(my_cols);
             file.close();
             alert(document.getElementById('offlineStrings').getString('list.columns_saved'));
@@ -459,7 +459,7 @@ util.list.prototype = {
             var my_cols;
             if (! obj.data.hash.aous) { obj.data.hash.aous = {}; }
             if (! obj.data.hash.aous['gui.disable_local_save_columns']) {
-                JSAN.use('util.file'); var file = new util.file('tree_columns_for_'+window.escape(id));
+                JSAN.use('util.file'); var file = new util.file('tree_columns_for_'+window.encodeURIComponent(id));
                 if (file._file.exists()) {
                     my_cols = file.get_object(); file.close();
                 }
@@ -468,7 +468,7 @@ util.list.prototype = {
             if (obj.data.hash.aous['url.remote_column_settings'] && ! my_cols ) {
                 try {
                     var x = new XMLHttpRequest();
-                    var url = obj.data.hash.aous['url.remote_column_settings'] + '/tree_columns_for_' + window.escape(id);
+                    var url = obj.data.hash.aous['url.remote_column_settings'] + '/tree_columns_for_' + window.encodeURIComponent(id);
                     x.open("GET", url, false);
                     x.send(null);
                     if (x.status == 200) {
index 395e50d..9617e61 100644 (file)
@@ -352,10 +352,6 @@ util.network.prototype = {
         var data = new OpenILS.data(); data.init({'via':'stash'});
         var my_xulG = win.open(
             url,
-            //+ '?login_type=staff'
-            //+ '&desc_brief=' + window.escape( text ? 'Session Expired' : 'Operator Change' )
-            //+ '&desc_full=' + window.escape( text ? 'Please enter the credentials for a new login session.' : 'Please enter the credentials for the new login session.  Note that the previous session is still active.'),
-            //'simple_auth' + (new Date()).toString(),
             offlineStrings.getString('network.new_session.authorize'),
             'chrome,resizable,modal,width=700,height=500',
             {
@@ -426,10 +422,6 @@ util.network.prototype = {
                     JSAN.use('util.window'); var win = new util.window();
                     var my_xulG = win.open(
                         urls.XUL_AUTH_SIMPLE,
-                        //+ '?login_type=temp'
-                        //+ '&desc_brief=' + window.escape('Permission Denied: ' + robj.ilsperm)
-                        //+ '&desc_full=' + window.escape('Another staff member with the above permission may authorize this specific action.  Please notify your library administrator if you need this permission.  If you feel you have received this exception in error, inform your friendly Evergreen developers of the above permission and this debug information: ' + name),
-                        //'simple_auth' + (new Date()).toString(),
                         offlineStrings.getFormattedString('network.permission.authorize'),
                         'chrome,resizable,modal,width=700,height=500',
                         {
@@ -509,8 +501,6 @@ util.network.prototype = {
                     JSAN.use('util.window'); var win = new util.window();
                     var fancy_prompt_data = win.open(
                         urls.XUL_FANCY_PROMPT,
-                        //+ '?xml_in_stash=temp_override_xml'
-                        //+ '&title=' + window.escape(override_params.title),
                         'fancy_prompt', 'chrome,resizable,modal,width=700,height=500',
                         { 'xml' : xml, 'title' : override_params.title, 'sound' : 'bad', 'sound_object' : obj.sound }
                     );
index 84de362..6ea9d19 100644 (file)
@@ -94,7 +94,7 @@
             <label value="&common.debug.label;" />
             <textbox id="debug_tb" flex="1"/>
             <button label="&common.debug.btn.execute;" oncommand="try { var dtb = document.getElementById('debug_tb'); alert( eval( dtb.value ) ); } catch(E) { alert(E); }; dtb.focus();"/>
-            <button label="&common.debug.btn.inspect;" oncommand="try { var dtb = document.getElementById('debug_tb'); var dx = eval( dtb.value ); var ds = ''; for (var di in dx) { ds += di + '=' + dx[di] + '\r\n'; }; window.open('data:text/plain;charset=UTF-8,'+window.escape(ds),'debug_win','chrome,resizable,modal'); } catch(E) { alert(E); }; dtb.focus();"/>
+            <button label="&common.debug.btn.inspect;" oncommand="try { var dtb = document.getElementById('debug_tb'); var dx = eval( dtb.value ); var ds = ''; for (var di in dx) { ds += di + '=' + dx[di] + '\r\n'; }; window.open('data:text/plain;charset=UTF-8,'+window.encodeURIComponent(ds),'debug_win','chrome,resizable,modal'); } catch(E) { alert(E); }; dtb.focus();"/>
             <button label="&common.debug.btn.js2JSON;" oncommand="try { var dtb = document.getElementById('debug_tb'); alert( js2JSON( eval( dtb.value ) ) ); } catch(E) { alert(E); }; dtb.focus();"/>
         </hbox>
         <keyset><key id="debug_box_key" keycode="VK_F7" modifiers="control,shift" oncommand="JSAN.use('OpenILS.data'); var data = new OpenILS.data(); data.init({'via':'stash'}); var dtb = document.getElementById('debug_tb'); var dx = document.getElementById('debug_box'); if(data.enable_debug || !dx.hidden) { dx.hidden = !dx.hidden; if(!dx.hidden) dtb.focus();}"/></keyset>
index d5f36ef..33add93 100644 (file)
@@ -386,10 +386,10 @@ admin.offline_manage_xacts.prototype = {
         for (var i = 0; i < obj.sel_list.length; i++) {
 
             var url  = xulG.url_prefix('XUL_OFFLINE_MANAGE_XACTS_CGI?ses=')
-                + window.escape(ses())
+                + window.encodeURIComponent(ses())
                 + "&action=execute" 
-                + "&seskey=" + window.escape(obj.seslist[obj.sel_list[i]].key)
-                + "&ws=" + window.escape(obj.data.ws_name);
+                + "&seskey=" + window.encodeURIComponent(obj.seslist[obj.sel_list[i]].key)
+                + "&ws=" + window.encodeURIComponent(obj.data.ws_name);
             var x = new XMLHttpRequest();
             x.open("GET",url,false);
             x.send(null);
@@ -419,10 +419,10 @@ admin.offline_manage_xacts.prototype = {
         obj.data.stash_retrieve();
 
         var url  = xulG.url_prefix('XUL_OFFLINE_MANAGE_XACTS_CGI?ses=')
-            + window.escape(ses())
+            + window.encodeURIComponent(ses())
             + "&action=status" 
-            + "&seskey=" + window.escape(obj.seslist[ obj.sel_list[0] ].key)
-            + "&ws=" + window.escape(obj.data.ws_name)
+            + "&seskey=" + window.encodeURIComponent(obj.seslist[ obj.sel_list[0] ].key)
+            + "&ws=" + window.encodeURIComponent(obj.data.ws_name)
             + '&status_type=exceptions';
         var x = new XMLHttpRequest();
         x.open("GET",url,false);
@@ -541,16 +541,6 @@ admin.offline_manage_xacts.prototype = {
         x.setAttribute(
             'src',
             window.xulG.url_prefix('XUL_REMOTE_BROWSER')
-            /*
-            + '?url=' + window.escape(
-                urls.XUL_OFFLINE_UPLOAD_XACTS
-                + '?ses=' + window.escape(ses())
-                + '&seskey=' + window.escape(seskey)
-                + '&ws=' + window.escape(obj.data.ws_name)
-                + '&delta=' + window.escape('0')
-                + '&filename=' + window.escape( obj.transition_filename )
-            )
-            */
         );
         var newG = { 
             'url' : urls.XUL_OFFLINE_UPLOAD_XACTS,
@@ -600,10 +590,10 @@ admin.offline_manage_xacts.prototype = {
         obj.data.stash_retrieve();
 
         var url  = xulG.url_prefix('XUL_OFFLINE_MANAGE_XACTS_CGI?ses=')
-            + window.escape(ses())
+            + window.encodeURIComponent(ses())
             + "&action=status" 
-            + "&seskey=" + window.escape(obj.seslist[obj.sel_list[0]].key)
-            + "&ws=" + window.escape(obj.data.ws_name)
+            + "&seskey=" + window.encodeURIComponent(obj.seslist[obj.sel_list[0]].key)
+            + "&ws=" + window.encodeURIComponent(obj.data.ws_name)
             + "&status_type=scripts";
         var x = new XMLHttpRequest();
         x.open("GET",url,false);
@@ -642,10 +632,10 @@ admin.offline_manage_xacts.prototype = {
         obj.data.stash_retrieve();
 
         var url  = xulG.url_prefix('XUL_OFFLINE_MANAGE_XACTS_CGI?ses=')
-            + window.escape(ses())
+            + window.encodeURIComponent(ses())
             + "&action=create" 
-            + "&desc=" + window.escape(desc)
-            + "&ws=" + window.escape(obj.data.ws_name);
+            + "&desc=" + window.encodeURIComponent(desc)
+            + "&ws=" + window.encodeURIComponent(obj.data.ws_name);
         var x = new XMLHttpRequest();
         x.open("GET",url,false);
         x.send(null);
@@ -677,9 +667,9 @@ admin.offline_manage_xacts.prototype = {
             obj.data.stash_retrieve();
 
             var url = xulG.url_prefix('XUL_OFFLINE_MANAGE_XACTS_CGI?ses=') 
-                + window.escape(ses())
+                + window.encodeURIComponent(ses())
                 + "&action=status"
-                + "&org=" + window.escape(obj.data.list.au[0].ws_ou())
+                + "&org=" + window.encodeURIComponent(obj.data.list.au[0].ws_ou())
                 + "&status_type=sessions";
             var x = new XMLHttpRequest();
             x.open("GET",url,false);
@@ -832,7 +822,6 @@ admin.offline_manage_xacts.prototype = {
             if (typeof window.xulG == 'object' && typeof window.xulG.new_tab == 'function') {
                 try {
                     var url = urls.XUL_COPY_STATUS;
-                        //+ '?barcodes=' + window.escape( js2JSON(barcodes) );
                     window.xulG.new_tab(
                         url, {}, { 'barcodes' : barcodes }
                     );
index 0ede94f..e5e0166 100644 (file)
@@ -209,7 +209,7 @@ function Bucketz39Dialog() {
         */
         var urls = this.xulG.urls || window.urls;
         var loc = urls.XUL_BROWSER + '?url=' + 
-            window.escape(
+            window.encodeURIComponent(
                 this.xulG.url_prefix('EG_WEB_BASE/') +
                 'vandelay/vandelay?qtype=bib&qid=' + this.queue.id()
             );
index b0f0155..532ec1b 100644 (file)
@@ -933,8 +933,6 @@ cat.copy_browser.prototype = {
                                     JSAN.use('util.window'); var win = new util.window();
                                     var fancy_prompt_data = win.open(
                                         urls.XUL_FANCY_PROMPT,
-                                        //+ '?xml_in_stash=temp_transfer'
-                                        //+ '&title=' + window.escape('Volume Transfer'),
                                         'fancy_prompt', 'chrome,resizable,modal,width=500,height=300',
                                         {
                                             'xml' : xml,
index 67f7971..0bd3fa6 100644 (file)
@@ -1526,7 +1526,6 @@ g.copy_notes = function() {
     JSAN.use('util.window'); var win = new util.window();
     win.open(
         urls.XUL_COPY_NOTES, 
-        //+ '?copy_id=' + window.escape(g.copies[0].id()),
         $("catStrings").getString("staff.cat.copy_editor.copy_notes"),'chrome,resizable,modal',
         { 'copy_id' : g.copies[0].id() }
     );
index b6aacd5..77b7408 100644 (file)
@@ -723,9 +723,6 @@ cat.record_buckets.prototype = {
                                 JSAN.use('util.window'); var win = new util.window();
                                 var fancy_prompt_data = win.open(
                                     urls.XUL_FANCY_PROMPT,
-                                    //+ '?xml_in_stash=temp_merge_mid'
-                                    //+ '&top_xml_in_stash=temp_merge_top'
-                                    //+ '&title=' + window.escape('Record Purging'),
                                     'fancy_prompt', 'chrome,resizable,modal,width=700,height=500',
                                     {
                                         'top_xml' : top_xml, 'xml' : xml, 'title' : $("catStrings").getString('staff.cat.record_buckets.delete_records.fancy_prompt_title')
index fe33321..7822c90 100644 (file)
         function preview_xul_190(html) {
             JSAN.use('util.window'); var win = new util.window();
             var loc = ( urls.XUL_REMOTE_BROWSER );
-            //+ '?url=' + window.escape('about:blank') + '&show_print_button=1&alternate_print=1&no_xulG=1&title=' + window.escape('Spine Labels');
             var w = win.open( loc, 'spine_preview', 'chrome,resizable,width=750,height=550');
             w.xulG = { 
                 'url' : 'about:blank',
index 2f47f67..e84ee95 100644 (file)
@@ -177,8 +177,6 @@ cat.util.transfer_copies = function(params) {
         JSAN.use('util.window'); var win = new util.window();
         var fancy_prompt_data = win.open(
             urls.XUL_FANCY_PROMPT,
-            //+ '?xml_in_stash=temp_transfer'
-            //+ '&title=' + window.escape('Item Transfer'),
             'fancy_prompt', 'chrome,resizable,modal,width=500,height=300',
             { 'xml' : xml, 'title' : $("catStrings").getString('staff.cat.util.transfer_copies.window_title') }
         );
@@ -671,7 +669,7 @@ cat.util.edit_new_brsrc = function(brsrc_list) {
     try {
         xulG.resultant_brsrc = brsrc_list.map(function(o) { return o[0]; });
         xulG.new_tab(
-            urls.XUL_BROWSER + "?url=" + window.escape(
+            urls.XUL_BROWSER + "?url=" + window.encodeURIComponent(
                 xulG.url_prefix("BOOKING_RESOURCE")
             ), {
                 "tab_name": offlineStrings.getString(
index d140e13..ff1c6f6 100644 (file)
@@ -946,9 +946,6 @@ cat.z3950.prototype = {
         JSAN.use('util.window'); var win = new util.window();
         var fancy_prompt_data = win.open(
             urls.XUL_FANCY_PROMPT,
-            // + '?xml_in_stash=temp_merge_mid'
-            // + '&top_xml_in_stash=temp_merge_top'
-            // + '&title=' + window.escape('Record Overlay'),
             'fancy_prompt', 'chrome,resizable,modal,width=700,height=500',
             { 'top_xml' : top_xml, 'xml' : xml, 'title' : $("catStrings").getString('staff.cat.z3950.confirm_overlay.title') }
         );
index 0b07021..c207a3a 100644 (file)
             var win = new util.window();
             var w = win.open(
                 urls.XUL_PATRON_BILL_WIZARD,
-                    //+ '?patron_id=' + window.escape(g.patron_id)
-                    //+ '&xact_id=' + window.escape( g.circ_id ),
                 'billwizard',
                 'chrome,resizable,modal',
                 { 'patron_id' : g.patron_id, 'xact_id' : g.circ_id }
index 8a2eca7..253a4cc 100644 (file)
@@ -1062,8 +1062,6 @@ circ.copy_status.prototype = {
                                     JSAN.use('util.window'); var win = new util.window();
                                     var fancy_prompt_data = win.open(
                                         urls.XUL_FANCY_PROMPT,
-                                        //+ '?xml_in_stash=temp_transfer'
-                                        //+ '&title=' + window.escape('Volume Transfer'),
                                         'fancy_prompt', 'chrome,resizable,modal,width=500,height=300',
                                         { 'xml' : xml, 'title' : document.getElementById('circStrings').getString('staff.circ.copy_status.transfer_volume.title') }
                                     );
index 92b168a..fa982eb 100644 (file)
@@ -4038,7 +4038,7 @@ circ.util.find_acq_po = function(session, copy_id) {
                 if (r = openils.Util.readResponse(r)) {
                     if (r.purchase_order()) {
                         var url = urls.XUL_BROWSER + "?url=" +
-                            window.escape(
+                            window.encodeURIComponent(
                                 xulG.url_prefix('EG_ACQ_PO_VIEW/')
                                     + r.purchase_order() + "/" + r.id()
                             );
index d2e2405..fa613b2 100644 (file)
                 if (typeof window.xulG == 'object' && typeof window.xulG.set_tab == 'function') {
                     window.xulG.set_tab( loc, {}, { 'barcode' : barcode } );
                 } else {
-                    location.href = loc + '?barcode=' + window.escape(barcode);
+                    location.href = loc + '?barcode=' + window.encodeURIComponent(barcode);
                 }
             } catch(E) {
                 g.error.standard_unexpected_error_alert($("patronStrings").getString('staff.patron.barcode_entry.patron_display_error'),E);
 
         function spawn_perm_editor(id) {
             try {
-                var loc = urls.XUL_USER_PERM_EDITOR + '?ses=' + window.escape(ses()) + '&usr=' + id;
+                var loc = urls.XUL_USER_PERM_EDITOR + '?ses=' + window.encodeURIComponent(ses()) + '&usr=' + id;
                 if (typeof window.xulG == 'object' && typeof window.xulG.set_tab == 'function') {
                     window.xulG.set_tab( loc, {}, {} );
                 } else {
index fd46a3b..87b50e2 100644 (file)
@@ -213,7 +213,6 @@ patron.display.prototype = {
                             obj.reset_nav_styling('cmd_patron_items');
                             var frame = obj.right_deck.set_iframe(
                                 urls.XUL_PATRON_ITEMS,
-                                //+ '?patron_id=' + window.escape( obj.patron.id() ),
                                 {},
                                 {
                                     'patron_id' : obj.patron.id(),
@@ -248,12 +247,7 @@ patron.display.prototype = {
 
                                 function spawn_editor(p) {
                                     var url = urls.XUL_PATRON_EDIT;
-                                    //var param_count = 0;
-                                    //for (var i in p) {
-                                    //    if (param_count++ == 0) url += '?'; else url += '&';
-                                    //    url += i + '=' + window.escape(p[i]);
-                                    //}
-                                    var loc = xulG.url_prefix('XUL_REMOTE_BROWSER'); // + '?url=' + window.escape( url );
+                                    var loc = xulG.url_prefix('XUL_REMOTE_BROWSER');
                                     xulG.new_tab(
                                         loc, 
                                         {}, 
@@ -282,11 +276,6 @@ patron.display.prototype = {
 
                             obj.right_deck.set_iframe(
                                 urls.XUL_REMOTE_BROWSER + '?patron_edit=1',
-                                //+ '?url=' + window.escape( 
-                                //    urls.XUL_PATRON_EDIT
-                                //    + '?ses=' + window.escape( ses() )
-                                //    + '&usr=' + window.escape( obj.patron.id() )
-                                //),
                                 {}, {
                                     'url' : urls.XUL_PATRON_EDIT,
                                     'show_print_button' : true,
@@ -484,7 +473,6 @@ patron.display.prototype = {
                                 obj.reset_nav_styling('cmd_patron_holds');
                                 obj.right_deck.set_iframe(
                                     urls.XUL_PATRON_HOLDS,    
-                                    //+ '?patron_id=' + window.escape( obj.patron.id() ),
                                     {},
                                     {
                                         'display_window' : window,
@@ -517,7 +505,6 @@ patron.display.prototype = {
                             obj.reset_nav_styling('cmd_patron_bills');
                             var f = obj.right_deck.set_iframe(
                                 urls.XUL_PATRON_BILLS,
-                                //+ '?patron_id=' + window.escape( obj.patron.id() ),
                                 {},
                                 {
                                     'display_window' : window,
@@ -581,7 +568,7 @@ patron.display.prototype = {
                     'cmd_perm_editor' : [
                         ['command'],
                         function() {
-                             var frame = obj.right_deck.reset_iframe( urls.XUL_USER_PERM_EDITOR + '?ses=' + window.escape(ses()) + '&usr=' + obj.patron.id(), {}, {});
+                             var frame = obj.right_deck.reset_iframe( urls.XUL_USER_PERM_EDITOR + '?ses=' + window.encodeURIComponent(ses()) + '&usr=' + obj.patron.id(), {}, {});
                         }
                     ],
                     'cmd_standing_penalties' : [
@@ -675,7 +662,7 @@ patron.display.prototype = {
                             } else {
                                 error = js2JSON(E).substr(0,100);
                             }
-                            xulG.set_tab(urls.XUL_PATRON_BARCODE_ENTRY + '?error=' + window.escape(error),{},{});
+                            xulG.set_tab(urls.XUL_PATRON_BARCODE_ENTRY + '?error=' + window.encodeURIComponent(error),{},{});
                         } catch(F) {
                             alert(F);
                         }
@@ -774,7 +761,7 @@ patron.display.prototype = {
                                 setTimeout(
                                     function() {
                                         var frame = obj.left_deck.set_iframe(
-                                            urls.XUL_PATRON_SUMMARY + '?id=' + window.escape(list[0]),
+                                            urls.XUL_PATRON_SUMMARY + '?id=' + window.encodeURIComponent(list[0]),
                                             {},
                                             {
                                                 //'id' : list[0],
index 67ad4a9..fdc6095 100644 (file)
@@ -379,7 +379,7 @@ patron.holds.prototype = {
                                     content_params[k] = xulG[k];
                                 });
 
-                                var loc = urls.XUL_BROWSER + "?url=" + window.escape(
+                                var loc = urls.XUL_BROWSER + "?url=" + window.encodeURIComponent(
                                     xulG.url_prefix("ALT_HOLDS_PRINT")
                                 );
                                 xulG.new_tab(
@@ -416,7 +416,7 @@ patron.holds.prototype = {
                                     content_params[k] = xulG[k];
                                 });
 
-                                var loc = urls.XUL_BROWSER + "?url=" + window.escape(
+                                var loc = urls.XUL_BROWSER + "?url=" + window.encodeURIComponent(
                                     xulG.url_prefix("/eg/circ/hold_pull_list").replace("http:","https:")
                                 );
                                 xulG.new_tab(
@@ -505,9 +505,6 @@ patron.holds.prototype = {
                                 JSAN.use('util.window'); var win = new util.window();
                                 var fancy_prompt_data = win.open(
                                     urls.XUL_FANCY_PROMPT,
-                                    //+ '?xml_in_stash=temp_mid'
-                                    //+ '&bottom_xml_in_stash=temp_bot'
-                                    //+ '&title=' + window.escape('Choose a Pick Up Library'),
                                     'fancy_prompt', 'chrome,resizable,modal',
                                     { 'xml' : xml, 'bottom_xml' : bot_xml, 'title' : $("patronStrings").getString('staff.patron.holds.holds_edit_selection_depth.choose_library') }
                                 );
@@ -573,9 +570,6 @@ patron.holds.prototype = {
                                 JSAN.use('util.window'); var win = new util.window();
                                 var fancy_prompt_data = win.open(
                                     urls.XUL_FANCY_PROMPT,
-                                    //+ '?xml_in_stash=temp_mid'
-                                    //+ '&bottom_xml_in_stash=temp_bot'
-                                    //+ '&title=' + window.escape('Choose a Pick Up Library'),
                                     'fancy_prompt', 'chrome,resizable,modal',
                                     { 'xml' : xml, 'bottom_xml' : bot_xml, 'title' : $("patronStrings").getString('staff.patron.holds.holds_edit_pickup_lib.choose_lib') }
                                 );
@@ -622,10 +616,6 @@ patron.holds.prototype = {
                                 JSAN.use('util.window'); var win = new util.window();
                                 var fancy_prompt_data = win.open(
                                     urls.XUL_FANCY_PROMPT,
-                                    //+ '?xml_in_stash=temp_mid'
-                                    //+ '&bottom_xml_in_stash=temp_bot'
-                                    //+ '&title=' + window.escape('Choose a Hold Notification Phone Number')
-                                    //+ '&focus=phone',
                                     'fancy_prompt', 'chrome,resizable,modal',
                                     { 'xml' : xml, 'bottom_xml' : bot_xml, 'title' : $("patronStrings").getString('staff.patron.holds.holds_edit_phone_notify.choose_phone_number'), 'focus' : 'phone' }
                                 );
@@ -673,10 +663,6 @@ patron.holds.prototype = {
                                 JSAN.use('util.window'); var win = new util.window();
                                 var fancy_prompt_data = win.open(
                                     urls.XUL_FANCY_PROMPT,
-                                    //+ '?xml_in_stash=temp_mid'
-                                    //+ '&bottom_xml_in_stash=temp_bot'
-                                    //+ '&title=' + window.escape('Choose a Hold Notification Phone Number')
-                                    //+ '&focus=phone',
                                     'fancy_prompt', 'chrome,resizable,modal',
                                     { 'xml' : xml, 'bottom_xml' : bot_xml, 'title' : $("patronStrings").getString('staff.patron.holds.holds_edit_sms_notify.choose_phone_number'), 'focus' : 'phone' }
                                 );
@@ -746,9 +732,6 @@ patron.holds.prototype = {
                                 JSAN.use('util.window'); var win = new util.window();
                                 var fancy_prompt_data = win.open(
                                     urls.XUL_FANCY_PROMPT,
-                                    //+ '?xml_in_stash=temp_mid'
-                                    //+ '&bottom_xml_in_stash=temp_bot'
-                                    //+ '&title=' + window.escape('Choose a Pick Up Library'),
                                     'fancy_prompt', 'chrome,resizable,modal',
                                     { 'xml' : xml, 'bottom_xml' : bot_xml, 'title' : $("patronStrings").getString('staff.patron.holds.holds_edit_sms_carrier.choose_carrier') }
                                 );
@@ -798,9 +781,6 @@ patron.holds.prototype = {
                                 JSAN.use('util.window'); var win = new util.window();
                                 var fancy_prompt_data = win.open(
                                     urls.XUL_FANCY_PROMPT,
-                                    //+ '?xml_in_stash=temp_mid'
-                                    //+ '&bottom_xml_in_stash=temp_bot'
-                                    //+ '&title=' + window.escape('Set Email Notification for Holds'),
                                     'fancy_prompt', 'chrome,resizable,modal',
                                     { 'xml' : xml, 'bottom_xml' : bot_xml, 'title' : $("patronStrings").getString('staff.patron.holds.holds_edit_email_notify.set_notifs') }
                                 );
index d27db59..6dba4a6 100644 (file)
@@ -323,13 +323,11 @@ function clone_patron() {
     try {
         for (var i = 0; i < g.sel_list.length; i++) {    
             var loc = xulG.url_prefix('XUL_REMOTE_BROWSER'); 
-                //+ '?url=' + window.escape( urls.XUL_PATRON_EDIT + '?ses=' 
-                //+ window.escape( ses() ) + '&clone=' + g.sel_list[i] );
             if (typeof window.xulG == 'object' && typeof window.xulG.new_tab == 'function') xulG.new_tab(
                 loc, 
                 {}, 
                 { 
-                    'url' : urls.XUL_PATRON_EDIT, // + '?ses=' + window.escape(ses()) + '&clone=' + g.sel_list[i],
+                    'url' : urls.XUL_PATRON_EDIT,
                     'show_print_button' : true , 
                     'tab_name' : $("patronStrings").getString('staff.patron.info_group.clone_patron.register_clone.tab_name'),
                     'passthru_content_params' : {
@@ -365,7 +363,7 @@ function spawn_editor(p) {
     for (var i in p) {
         passthru[i] = p[i];
     }
-    var loc = xulG.url_prefix('XUL_REMOTE_BROWSER'); // + '?url=' + window.escape( url );
+    var loc = xulG.url_prefix('XUL_REMOTE_BROWSER');
     if (typeof window.xulG == 'object' && typeof window.xulG.new_tab == 'function') xulG.new_tab(
         loc, 
         {}, 
@@ -505,10 +503,6 @@ function link_patron(direction) {
             JSAN.use('util.window'); var win = new util.window();
             var fancy_prompt_data = win.open(
                 urls.XUL_FANCY_PROMPT,
-                //+ '?xml_in_stash=temp_mid'
-                //+ '&top_xml_in_stash=temp_top'
-                //+ '&bottom_xml_in_stash=temp_bot'
-                //+ '&title=' + window.escape('Move Patron into a Usergroup'),
                 'fancy_prompt', 'chrome,resizable,modal,width=700,height=500',
                 { 'xml' : xml, 'top_xml' : top_xml, 'bottom_xml' : bot_xml, 'title' : $("patronStrings").getString('staff.patron.info_group.link_patron.move_patron_to_usergroup')}
             );
index f655944..463f15e 100644 (file)
@@ -738,8 +738,6 @@ patron.items.prototype = {
                 var circ_id = retrieve_ids[i].circ_id;
                 var my_xulG = win.open(
                     urls.XUL_PATRON_BILL_WIZARD,
-                        //+ '?patron_id=' + window.escape(obj.patron_id)
-                        //+ '&xact_id=' + window.escape( circ_id ),
                     'billwizard',
                     'chrome,resizable,modal',
                     { 'patron_id' : obj.patron_id, 'xact_id' : circ_id }
index e5fece2..e837145 100644 (file)
@@ -301,8 +301,6 @@ serial.manage_dists.prototype = {
                                     JSAN.use('util.window'); var win = new util.window();
                                     var fancy_prompt_data = win.open(
                                         urls.XUL_FANCY_PROMPT,
-                                        //+ '?xml_in_stash=temp_transfer'
-                                        //+ '&title=' + window.escape('Volume Transfer'),
                                         'fancy_prompt', 'chrome,resizable,modal,width=500,height=300',
                                         {
                                             'xml' : xml,
index a11fb82..7ac9ff4 100644 (file)
@@ -572,8 +572,6 @@ serial.manage_subs.prototype = {
                                     JSAN.use('util.window'); var win = new util.window();
                                     var fancy_prompt_data = win.open(
                                         urls.XUL_FANCY_PROMPT,
-                                        //+ '?xml_in_stash=temp_transfer'
-                                        //+ '&title=' + window.escape('Volume Transfer'),
                                         'fancy_prompt', 'chrome,resizable,modal,width=500,height=300',
                                         {
                                             'xml' : xml,
index de14903..d080f8a 100644 (file)
@@ -278,7 +278,6 @@ serial.sdist_editor.prototype = {
         JSAN.use('util.window'); var win = new util.window();
         win.open(
             urls.XUL_SERIAL_NOTES, 
-            //+ '?copy_id=' + window.escape(obj.sdists[0].id()),
             $('serialStrings').getString('staff.serial.sdist_editor.notes'),'chrome,resizable,modal',
             { 'object_id' : obj.sdists[0].id(), 'function_type' : 'SDISTN', 'object_type' : 'distribution', 'constructor' : sdistn }
         );
index f057210..dc1b56e 100644 (file)
@@ -168,7 +168,6 @@ serial.sitem_editor.prototype = {
         JSAN.use('util.window'); var win = new util.window();
         win.open(
             urls.XUL_SERIAL_NOTES, 
-            //+ '?copy_id=' + window.escape(obj.sitems[0].id()),
             'Item Notes','chrome,resizable,modal',
             { 'object_id' : obj.sitems[0].id(), 'function_type' : 'SIN', 'object_type' : 'item', 'constructor' : sin }
         );