i have an array of checkboxes (Surgery, Optometry, Dentistry, etc...) that are imploded into an array of data and inserted into a table.field as part of a Job Posting.
Code: Select all
$checkbox1 = $_POST['specialty'];
$string1 = implode($checkbox1,", ");
$checkbox2 = $_POST['subspecialty'];
$string2 = implode($checkbox2,", ");
$sql="INSERT INTO $tbl_user (username, password, specialty, subspecialty)
VALUES (\"$_POST[username]\", \"$_POST[password]\", \"$string1\", \"$string2\")";
i know to do this:
$sql="SELECT * FROM $tbl_user WHERE specialty CONTAINS ($string1)";
but i don't know how to get the selected values into the Search query...
does that make sense?
appreciate any help!
GN