b@1402: Could not open file'; b@1402: echo $xml; b@1402: return; b@1402: } b@1402: $wbytes = fwrite($fileHandle, $postText); b@1402: if ($wbytes == FALSE) b@1402: { b@1402: // FileWrite failed b@1402: $xml = 'Could not write file "saves/'.$xmlfile.'"'; b@1402: echo $xml; b@1402: return; b@1402: } b@1402: fclose($fileHandle); b@1402: b@1402: // Return JSON confirmation data b@1402: $xml = 'OK"saves/'.$xmlfile.'"'; b@1402: echo $xml; b@1402: ?>