Lets say i have a string as so
$string = "12 Days Of Terror";
and i want to break down this string at each space and insert each word into my DB.
the table: tags
Columns: movie
, tagname
Value: 10开发者_如何学编程2
, $string
how would you write the query for this?
Just split the string using explode: http://php.net/manual/en/function.explode.php and then insert each tag in the table.
精彩评论