我想使用AMF PHP將變量傳遞給一個Flash文件,到目前爲止我看不到任何錯誤的代碼,但是我創建類的經驗很少,所以在這裏,這裏是我的代碼,實例化一個AMF PHP類不工作
的index.php:
<?php
include "amfphp/services/flashMe.php";
$session = true;
if ($session == true) {
$uid = '12345';
$thing = new flashMe;
$thing->push($uid);
} else {
//login
}
?>
flashMe.php:
<?php
class flashMe {
public function __construct() {
}
public function push($one)
{
return $one;//sends the uid to the flash file?
}
}
?>
閃存正在尋找flashMe類和類中的push方法,但我一直G當我運行它時,在我的Flash文件中設置空變量,這個代碼有什麼問題嗎?
Thanx提前!
Btw,如果它是空的,不需要__construct()。 – bPizzi 2010-07-09 14:10:53
酷,thanx會放棄它。但是有可能實現我想要的嗎?因爲我沒有將變量發送到amf php並讓flash收到它。 – Odyss3us 2010-07-10 10:43:52