Ich habe ein kleines Script erstellt, indem man eine Bestellung abgeben kann (nur zum Testen). Ich bekomme die Variablen von PHP zu Flash aber nicht umgekehrt. Ich habe schon in vielen Tutorials etc. nachgeschaut, aber ich habe es genauso und bei mir geht es trotzdem nicht, hier die Scripts:
Actionscript:
Und PHP:
Was stimmt hier nicht?
Actionscript:
PHP:
var mylv:LoadVars = new LoadVars();
mylv.vemail = email;
mylv.vbetreff = betreff;
mylv.vinhalt = inhalt;
mylv.vanzahl = anzahl;
mylv.onLoad = function(success:Boolean) {
if (success) {
popup.error = popup.error+this.test;
}
else {
popup.error = popup.error+"Fehler beim Übertragen der Daten!";
}
};
mylv.sendAndLoad("s4g.php", mylv, "POST");
Und PHP:
PHP:
<?php
$email = $_POST["vemail"];
$betreff = $_POST["vbetreff"];
$inhalt = $_POST["vinhalt"];
$anzahl = $_POST["vanzahl"];
echo "&test=$betreff";
?>
Was stimmt hier nicht?