Re: Need help

From: Date: Tue, 26 Sep 2000 05:00:11 +0000
Subject: Re: Need help
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-17526@lists.php.net to get a copy of this message
On Tue, 26 Sep 2000, root wrote: > I want to compare 3 variables (user_id1,user_id2,user_id3) and result of > this command : > > > $sql1=mysql_query("SELECT user_id FROM daftarmail WHERE > user_id=$user_id1",$konek); > > // Nomor baris sql1 > $nomorbaris1=mysql_num_rows($sql1); > for ($i=0;$i=<$nomorbaris1;$i++) > { > $hasil1=mysql_result($sql1,$i,"user_id") if(($hasil1==$userid1) || ($hasil1==$userid2) || ($hasil1==$userid3)){ do_something(); //if any of userid1,2or 3 match hasil1 } > > can anyone help me with that? > > rgds, > > maurice -- David Robley | WEBMASTER & Mail List Admin RESEARCH CENTRE FOR INJURY STUDIES | http://www.nisu.flinders.edu.au/ AusEinet | http://auseinet.flinders.edu.au/ Flinders University, ADELAIDE, SOUTH AUSTRALIA

« previous php.general (#17526) next »