|
-
As2 php text file issue
Basically, I have one php file on my server which shows all files in a directory, a flash file to load the data, another php file that takes the names of the directory's files from flash and attempts to load the text files into flash. I can't figure out what's wrong with it, only that when flash catches the print/echo from php, it skips over the variable $theData which contains all the text file information. Any help would be appreciated. Thanks
AS2 Code:
var text_In:LoadVars = new LoadVars();
var text_Out:LoadVars = new LoadVars();
text_In.onLoad = function() {
reader = text_In.book;
};
thing.onEnterFrame = function() {
text_Out.bookname = load_Bookname;
text_Out.sendAndLoad("http://lozdod.zxq.net/book_loader.php",text_In,"GET");
};
Text File Loading PHP Code:
<?php
$myFile = $_GET['bookname'];
$fh = fopen("./books/$myFile", 'r');
$theData = fread($fh, filesize($myFile));
fclose($fh);
print "&book= $theData";
?>
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|