you must to close the for() {} ,,,,
put your correct code that it is below ...
<?
mysql_pconnect ("localhost", "UN", "PW");
mysql_select_db ("DB");
$qResult = mysql_query ("SELECT eventDate, title, startTime, endTime FROM
nuke_4ncal WHERE YEAR(eventDate) >= 2005 ORDER BY eventDate ASC");
$nRows = mysql_num_rows($qResult);
$rString ="&n=".$nRows;
for ($i=0; $i< $nRows; $i++){
$row = mysql_fetch_array($qResult);
$rString
..="&eventDate".$i."=".$row['eventDate']."&entry".$i."=".$row['entry'];
$rString .="&title".$i."=".$row['title']."&entry".$i."=".$row['entry'];
$rString
..="&startTime".$i."=".$row['startTime']."&entry".$i."=".$row['entry'];
$rString .="&endTime".$i."=".$row['endTime']."&entry".$i."=".$row['entry'];
echo "&rString=$rString&";
}
?>
to list this code in your flash look this ...
mike = new LoadVars();
mike.onLoad = function(ok) {
if(ok) {
rString = this.rString;
trace(rString);
}
}
mike.load("file.php");
[]´s
--
Gustavo Teider ( gugateider )
www.gugateider.com Curitiba - PR
"MikeZfoundre" <webforumsuser@macromedia.com> escreveu na mensagem
news:dd6p6k$3ki$1@forums.macromedia.com...
[quoted text, click to view] >I have the following php and it is returning errors. i am wondering what
>might
> be causeing this to kick up errors because I need to create the echo URL
> encoded string to load into flash.
>
>
>
> <?
>
> mysql_pconnect ("localhost", "UN", "PW");
> mysql_select_db ("DB;
>
> $qResult = mysql_query ("SELECT eventDate, title, startTime, endTime
> FROM nuke_4ncal
> WHERE YEAR(eventDate) >= 2005
> ORDER BY eventDate ASC");
>
> $nRows = mysql_num_rows($qResult);
> $rString ="&n=".$nRows;
>
> for ($i=0; $i< $nRows; $i++){
> $row = mysql_fetch_array($qResult);
>
> $rString
> .="&eventDate".$i."=".$row['eventDate']."&entry".$i."=".$row['entry'];
> $rString .="&title".$i."=".$row['title']."&entry".$i."=".$row['entry'];
> $rString
> .="&startTime".$i."=".$row['startTime']."&entry".$i."=".$row['entry'];
> $rString
> .="&endTime".$i."=".$row['endTime']."&entry".$i."=".$row['entry'];
>
> echo $rString."&";
>
> ?>
>