Hello, I am some days before the deadline of a project, and I ve been for the last 5 days trying to upload my project to the web server. While it was local it was working fine.
Uploaded to the server, with Apache + php 5 (I have never done that before, dont know much to describe it better..)
Its ok when I call my metod in the /browser:
diadafeira = "quinta, dia 24 de maio."
sepassou = "1"
[1] (Object)#2
diadafeira = "oioioio"
sepassou = "0"
But the text box that should out put this data in the swf remains blank,
here is my as3 code wich I am developing in Flash cs5.5:
var array:Array = [];
var _netConnection2:NetConnection = new NetConnection();
_netConnection2.connect("
http://www.site.com.br/horta_virtual/amfphp/gateway.php");
_netConnection2.call("HortalicasService/getData", new Responder(listData2, null));
function listData2(dados2:Object):void
{
for( var item2:Object in dados2 )
{
array.push( { day: dados2[item2].dayfair, yes:dados2[item2].ifpast} )
}
onload();
}
function onload()
{
for (var i:int= 0 ; i< array.length ; i++)
{
if ( array
.yes==1)
{
data_txt.text= array.day
}
}
}
here is the php:
<?php
class HortalicasService2 {
public function getData(){
$conexao = mysql_connect('localhost', "db_loginl", "db_password") or die(mysql_error());
$db = mysql_select_db("db_name") or die(mysql_error());
$query = "SELECT * FROM date";
$resultado = mysql_query($query);
$resultado_array = array();
$i = 0;
while ($dados2 = mysql_fetch_object($resultado)){
$resultado_array[$i] = array();
$resultado_array[$i]['diadafeira'] = $dados2->dayfair;
$resultado_array[$i]['sepassou'] = $dados2->sepassou;
$i++;
}
return $resultado_array;
}
}
?>
I have checked for spaces before anda after <?php...
I have deleted the htaccess...
And read lots of things..
Dont know what else to do, would you guys kindly help me? thank you
obrigada! =)