What is the problem with the following .fla which tries to send data from flash to php?
The php script is as follows:
<?php
$name=HTTP_POST_VARS[‘name’];
$comments=HTTP_POST_VARS[‘comments’];
echo $comments
?>
I get the following error when the .swf and .php are hosted on the lycos.co.uk server:
Parse error: parse error in /data/members/free/tripod/uk/m/y/p/myperception/htdocs/sendtophp.php on line 3
Please download the .fla and help.
system
July 19, 2003, 7:57am
2
sorry echo $comments;
just a typo but that is not the error;
system
July 19, 2003, 8:05am
3
<?
$name= $_POST['name'];
$comments= $_POST['comments'];
echo $comments;
?>
system
July 19, 2003, 8:21am
4
to ahmed:Thank you so much! I was so delighted to see Flash send data to php. Your reply solved the problem
Could you tell me what HTTP_POST_VARS and $_POST are? Also I saw something like:HTTP_RAW_POST_VARS.
Thanks again for the help, ahmed
system
July 19, 2003, 8:33am
5
glad it worked
$_POST is simply a rename for the old $HTTP_POST_VARS… the php community thought that the array’s name was too long, so they replaced it by a shorter one
about the http_raw_post_vars, i didn’t deal with that before, but you’re welcome to look it up on the php.net documentation :beam:
system
July 19, 2003, 12:53pm
6
usefull for xml, set to off be default…