Re: Newbie - help with a foreach

From: Date: Fri, 19 Jan 2007 10:45:08 +0000
Subject: Re: Newbie - help with a foreach
References: 1 2 3 4 5 6 7  Groups: php.general 
Request: Send a blank email to php-general+get-247391@lists.php.net to get a copy of this message
On cs, 2007-01-18 at 20:46 +0100, Jochem Maas wrote: > Németh Zoltán wrote: > > On cs, 2007-01-18 at 02:04 -0800, pub wrote: > >> On Jan 18, 2007, at 2:00 AM, Németh Zoltán wrote: > >> > > > ... > > > maybe you should use a parameter for it, place it into the link in the > > first query loop, get it here and query based on it > > > > like "SELECT * FROM job WHERE id={$_GET['job_id']}" or whatever > > SQL INJECTION WAITING TO HAPPEN. true, sorry so check the value first greets Zoltán Németh > > > ... > > >> foreach($row as $url) > >> { > >> $row = mysql_fetch_array($result2,MYSQL_ASSOC); > >> if ("url={$row['url']}") > > what is this IF statement supposed to be doing??? > because it will always evaluate to true

« previous php.general (#247391) next »