changeset 2753:1ba5ac9d88e7

More PHP work
author Nicholas Jillings <nicholas.jillings@mail.bcu.ac.uk>
date Tue, 25 Apr 2017 12:06:29 +0100
parents a99c5f008c2d
children 8eb4de917ee6
files php/requestKey.php
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/php/requestKey.php	Tue Apr 25 12:03:25 2017 +0100
+++ b/php/requestKey.php	Tue Apr 25 12:06:29 2017 +0100
@@ -58,7 +58,8 @@
 $doc_struct = new DOMDocument;
 $doc_struct->preserveWhiteSpace = false;
 $doc_struct->formatOutput = true;
-$doc_struct->loadXML("<waetresult key=\"".$key."\"/>");
+$doc_struct->loadXML("<waetresult />");
+$doc_struct->documentElement->setAttribute("key", $key);
 // Add the root
 if (file_exists($testURL)) {
     $test_proto_doc = new DOMDocument;