Hi
I am building an online tests system for a school , where the questions and answers are saved in an xml file on the school website server , the problem is i don’t know how can i save the xml file on the server and how can i call it back ?
My Code till now
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using System.Xml.Serialization;
using System.IO;
using System;
public class XMLSerializer : MonoBehaviour {
public string studentname;
public void fff() {
string path = "d:/" + "studentanswer"+ ".xml";
Debug.Log (path);
XmlSerializer serializer = new XmlSerializer (typeof(Level1));
Level1 ak47 = new Level1{ Items=new [] {new mainitems { Question = "a", Answer = "2" },new mainitems { Question="b",Answer="5"}}};
StreamWriter writer = new StreamWriter(path);
serializer.Serialize(writer, ak47);
writer.Close();
}
}