# Send variables from flash to php without reloading the page

**URL:** <https://forum.kirupa.com/t/send-variables-from-flash-to-php-without-reloading-the-page/58187>\
**Category:** Uncategorized\
**Created:** [July 20, 2004, 2:48pm UTC](https://forum.kirupa.com/t/send-variables-from-flash-to-php-without-reloading-the-page/58187 "2004-07-20T14:48:36Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sapnagumi](https://avatars.discourse-cdn.com/v4/letter/s/bcef8e/32.png) [@sapnagumi](https://forum.kirupa.com/u/sapnagumi)\
**Post date:** [July 20, 2004, 2:48pm UTC](https://forum.kirupa.com/t/send-variables-from-flash-to-php-without-reloading-the-page/58187/1 "2004-07-20T14:48:36Z")

</div>

Hi,  
I know there were many messages posted regarding sending variables from flash to php. But I am facing a problem. I wrote a small code where in I used send() method of LoadVar object, it sends the message but it reloads the php page which I do not want it to do. I tried using sendAndLoad() and here it does not send any variable at all. Below is my sample code. Please can anyone tell me where I am going wrong

PHP code: (recieve.php)  
\<?php  
$s = “12”;  
$r = $\_POST[‘name’];  
echo $r;  
?\>  
\<embed name=“move” src=“static.swf” height=250 width=250 play=“false” loop=“false” quality=“high”\>

Flash code:  
c = new LoadVars();  
c.onLoad = function() { trace(this.s); };  
c.name = “xyz”;  
x.sendAndLoad(“receive.php”, c, “POST”);
