Something
public text v1 · immutable $searchtext = $_POST['search'];
$temp = explode(" ", $searchtext);
for ($i=0; $i<count($temp); $i++) {
$result = mysql_query("SELECT * FROM files WHERE tags LIKE '%".$temp[$i]."%'") or die(mysql_error());;
if (mysql_num_rows($result) > 0) {
while ($row = mysql_fetch_array($result)) {
echo "Name :{$row['name']} <br>" .
"Description : {$row['desc']} <br>" .
"Location : {$row['location']} <br></a> " .
"Tags : {$row['tags']} <br>";