PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Moderator: General Moderators
pinehead18
Forum Contributor
Posts: 329 Joined: Thu Jul 31, 2003 9:20 pm
Post
by pinehead18 » Fri Jan 14, 2005 10:00 pm
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
timvw
DevNet Master
Posts: 4897 Joined: Mon Jan 19, 2004 11:11 pm
Location: Leuven, Belgium
Post
by timvw » Fri Jan 14, 2005 10:06 pm
get yourself a decent php editor
$output .=" stuff stfuf stuff";
$location = $row['city'];
magicrobotmonkey
Forum Regular
Posts: 888 Joined: Sun Mar 21, 2004 1:09 pm
Location: Cambridge, MA
Post
by magicrobotmonkey » Sat Jan 15, 2005 8:38 am
i think what you want is
Code: Select all
$location = $rowї'city']."more stuff";
//not
$location = $rowї'city'];."more stuff";