cannot seem to read a plain text file
this is actually macromedia flash mx 6.0, which I believe runs AS2 but is compatible with AS3
file = date.txt
file contents: xdate=12/01/2013
the file is in same directory as the .swf
code to read the file contents into a variable:
DateFile = new LoadVars();
DateFile.onLoad = function(ok) {
if (ok) {
var theDate = DateFile.xdate;
}
};
DateFile.load("date.txt");
theDate variable is empty
also tried this
file = date.txt
file contents: &xdate=12/01/2013&
DateFile = new LoadVars();
DateFile.load("date.txt");
var theDate = DateFile["xdate"];
