function quickGo(id) { var select = dojo.byId(id); var index = select.selectedIndex; var url = select.options[index].value; window.location = '/p/' + url; } function qcm(title) { if (dijit.byId('qcmDialog')) { dijit.byId('qcmDialog').destroy(); } var html = ""; dojo.xhrGet({ url: '/admin-site/qcm_show.php', handleAs: "text", sync: true, load: function(data) { html = data } }); var qcmDialog = new dijit.Dialog({ id: "qcmDialog", title: title, content: html, style: "width: 300px; overflow: auto" }); qcmDialog.show(); } function copyright() { if (!dijit.byId('copyrightDialog')) { var copyrightDialog = new dijit.Dialog({ id: "copyrightDialog", title: "Copyright", href: "/templates/v5/copyright.php", style: "width: 500px" }); copyrightDialog.show(); } else { dijit.byId('copyrightDialog').show(); } return false; } function newDialog(title, url, width, height) { if (dijit.byId('popupDialog')) { dijit.byId('popupDialog').attr('title', title); //dijit.byId('popupDialog').set('href', url); //dijit.byId('popupDialog').refresh(); dijit.byId('popupDialog').show(); return; } var w = 500; if (typeof(width) != "undefined" && width) { w = width; } if (typeof(height) != "undefined" && height) { var myDialog = new dijit.Dialog({ id: "popupDialog", title: title, href: url, style: "width: " + w + "px; height: " + height + "px; overflow: auto" }); } else { var myDialog = new dijit.Dialog({ id: "popupDialog", title: title, href: url, style: "width: " + w + "px" }); } myDialog.show(); return false; }