Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

Convert String containing commas to array

$string = "'1', '2', '3'"; 
$string = str_replace("'", '', $string);

$sql = "SELECT * FROM name WHERE id NOT IN ( " . implode(",", explode(',',$string)) . ") LIMIT 10 ";
echo $sql;
 
PREVIOUS NEXT
Tagged: #Convert #String #commas #array
ADD COMMENT
Topic
Name
7+9 =