finding a value in an array

From: Date: Mon, 04 Nov 2002 12:19:57 +0000
Subject: finding a value in an array
Groups: php.general 
Request: Send a blank email to php-general+get-122661@lists.php.net to get a copy of this message
I have a database table that holds the values of IDs in the format 1,2,3,4,5,67,x,x,x,x,x,x I am using a dynamic select list menu that displays a list of items from a 2nd table with the values set to their unique ids eg <option vaue =1>item 1</option> <option vaue =2>item2</option> <option vaue =3>item 3</option> <option vaue =4>item 4</option> <option vaue =5>item 5</option> i am trying to use an array search that will highlight the item if the option value is in the array of the IDs, but with no luck, either all the ids are highlighted or none at all Does any one have any suggestions into how to do this Thanks Craig

« previous php.general (#122661) next »