If () dont get it

Hello I will introduce myself. I am a PHP programmer who wants to combine PHP with Flash. I work with Flash 2004 MX.

My question is:
I have a PHP script who sends a variabel back to Flash named: valid

I have the folowing code but this does nothing…it is like the value valid is lost.
Flash code:

 loadVariables("../PHP/login.php", "/", "GET");
if (valid=="ok"){
getURL("../PHP/auth.php","_blank","POST");
}else{}
stop(); 

Please help… the if () then () else does work strange with actionscript when reading PHP…

Example if you have:
login.php

<?php
if (expression){
echo "&valid=ok&";}
else{
echo "&valid=not ok&";} ?> 

Reading this back does not do anything or in a Dynamic text field you always see not ok!! after processing valid=ok…

Thank you…
Greetings Ben