Loading var from txt or php file
| From: | pei_world | Date: | Fri, 28 Feb 2003 22:52:33 +0000 |
| Subject: | Loading var from txt or php file | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-137643@lists.php.net to get a copy of this message | ||
I have a flash written to receive var from php file.
but I found one problem,
my problem is just can load the var from the file.
I have following AS code from a button. when I click this button twice, it
load up the var
but How can I load it befor the moive is going to play?
there is no point to ask user click one button before select the combo box
right?
again, thanks for help.
//====================================
on (release) {
play();
loadVariables("test.txt", this); // get the data from php file
trace(array_num);
test='';
for(g=0; g<array_num; g++){
buy[g]=this["buy"+g];
sell[g]=this["sell"+g];
test+=this["buy"+g]+" - ";
}
for(m=0; m<array_num; m++){
test+=this["sell"+m]+" ~ ";
}
iList = new Array();
myItem = new Object();
myItem.label="Select one";
myItem.data = -1;
iList[0] = myItem;
for (i=0; i<array_num; i++) {
myItem = new Object();
get_label = this["list_label"+i]
myItem.label = get_label;
myItem.data = i;
iList[i+1] = myItem;
}
list_currency.setDataProvider(iList);
trace(get_label);
}
//===============================
--
Sincerely your;
pei_world ( .::IT::. )