Page 1 of 1

Simple problem

Posted: Fri Jan 14, 2005 10:00 pm
by pinehead18
My script is laid out like this.

Code: Select all

$output .=" stuff stfuf stuff".
        $result = mysql_query("SELECT user,mainpic,city FROM users WHERE mainpic <> 'default.gif' ORDER BY rand()");
        $row = mysql_fetch_array($result);
        
                $mainpic = $row['mainpic'];
                $uname = $row['user'];
                $location = $row['city'];."
                   more stuff";
yet i get a '.' error. Any ideas?

thank you
anthony

Re: Simple problem

Posted: Fri Jan 14, 2005 10:06 pm
by timvw
get yourself a decent php editor

$output .=" stuff stfuf stuff";
$location = $row['city'];

Posted: Sat Jan 15, 2005 8:38 am
by magicrobotmonkey
i think what you want is

Code: Select all

$location = $row&#1111;'city']."more stuff"; 

//not

 $location = $row&#1111;'city'];."more stuff";