# Pass on to simple txt file

**URL:** https://forum.kirupa.com/t/pass-on-to-simple-txt-file/223750
**Category:** Uncategorized
**Created:** [April 25, 2007, 2:17pm UTC](https://forum.kirupa.com/t/pass-on-to-simple-txt-file/223750 "2007-04-25T14:17:44Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![fabrice](https://avatars.discourse-cdn.com/v4/letter/f/5fc32e/32.png) [@fabrice](https://forum.kirupa.com/u/fabrice)
#### Post date: [April 25, 2007, 2:17pm UTC](https://forum.kirupa.com/t/pass-on-to-simple-txt-file/223750/1 "2007-04-25T14:17:44Z")

</div>

Hi to all  
I’m about 1/4 light year away from understanding that php language, thanks for your help.  
I am building a little application in between a flash project, a bit of php and text file.

So here it is,  
I am sendind my variables from my flash file with

compteur\_lv = new LoadVars();  
page1\_btn.onRelease = function() {  
compteur\_lv.val = val1;  
compteur\_lv.loadVariables(“compteur.php”, “POST”);  
};

So I was hoping the compteur.php file would get that val variable and pass it on to the “checker.txt” with this little bit of magic:

\<?php  
$val= $\_POST[“val”];  
$filename = ‘checker.txt’;  
$handle = fopen($filename, ‘w+’);  
fwrite($handle, ‘$val’);  
?\>  
but then, nothing happens in my checker.txt

Thanks for your help.  
Fabrice
