Solved issue#19, added default XML
This commit is contained in:
		| @@ -11,6 +11,18 @@ function clearDefaultContent(element, text) { | ||||
|     } | ||||
| } | ||||
|  | ||||
| function fillDefaultXML(element) { | ||||
|     if(element.classList.contains("active")){ | ||||
|         const serverAddress = window.location.protocol + "//" + window.location.hostname + ":8086"; | ||||
|         clearDefaultContent(document.getElementById("xmlArea"), "Insert XML here"); | ||||
|         fetch(serverAddress + "/assets/samples/sampleXml.xml") | ||||
|             .then(response => response.text()) | ||||
|             .then((exampleData) => { | ||||
|                 document.getElementById("xmlArea").value = exampleData; | ||||
|             }) | ||||
|             } | ||||
|         } | ||||
|  | ||||
| //Set default text in grey | ||||
| function setDefaultContent(element, text) { | ||||
|     if (element.value == "") { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user