Mercurial > hg > webaudioevaluationtool
diff core.js @ 1094:a589dab20020
Fixed null/period saves on test completion. specification projectReturn is currently deprecated pending new usage.
author | Nicholas Jillings <n.g.r.jillings@se14.qmul.ac.uk> |
---|---|
date | Thu, 10 Mar 2016 11:49:08 +0000 |
parents | e4b378468589 |
children | 6dac24365cfe |
line wrap: on
line diff
--- a/core.js Thu Mar 10 10:04:38 2016 +0000 +++ b/core.js Thu Mar 10 11:49:08 2016 +0000 @@ -334,16 +334,17 @@ popup.popupContent.appendChild(a); } else { var xmlhttp = new XMLHttpRequest; - xmlhttp.open("POST",destURL,true); + xmlhttp.open("POST","\save.php?key="+storage.SessionKey.key,true); xmlhttp.setRequestHeader('Content-Type', 'text/xml'); xmlhttp.onerror = function(){ console.log('Error saving file to server! Presenting download locally'); - createProjectSave(null); + createProjectSave("local"); }; xmlhttp.onload = function() { console.log(xmlhttp); if (this.status >= 300) { console.log("WARNING - Could not update at this time"); + createProjectSave("local"); } else { var parser = new DOMParser(); var xmlDoc = parser.parseFromString(xmlhttp.responseText, "application/xml");