TypeError: Error #2007: Parameter text must be non-null.
at flash.text::TextField/set text()
at MethodInfo-1()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/onComplete()
here is the php:
Code: Select all
<?php
// Only run this script if the sendRequest is from our flash application
//if ($_POST['sendRequest'] == "parse") {
// Access the value of the dynamic text field variable sent from flash
$uname = $_POST['uname'];
$connect = mysql_connect("---","---","---") or die ("Could not connect to mysql because ".mysql_error());;
mysql_select_db("c3site1",$connect);
$query = "SELECT price FROM partno WHERE partnum LIKE 'C3SI3C05I-D0'";
$results = mysql_query($query);
while ($row = mysql_fetch_assoc($results)) {
extract ($row);
echo "price = $price";
}
// Print two vars back to flash, you can also use "echo" in place of print
print "var1=The name field with a variable of $uname has been sent to PHP and is back.";
//print "&var2=$uname is also set in variable 2 from PHP. $results [$row]";
print "&var2=test" . $price;
//}When I view the php I see the price appear:
price = 853.99var1=The name field with a variable of has been sent to PHP and is back.&var2=test853.99
I can see the data (853.99) being sent back from the DB but I am unable to run the swf because of errors in this php file. I have tried the origional swf with the origional php (i am working from a template) and the swf works fine so I know that the error is here in the php.
The I understand that a zero is being set to a variable and the problem is simply the order of lines being executed. any ideas?
thanks,
Jarrett