New to php. I'm having trouble determining the error in my code. I keep getting this error
Parse error: syntax error, unexpected 'preg_match' (T_STRING) in /Applications/MAMP/htdocs/blackiris/blackiris/syriaexhibition/syriaexhibition.php on line 16
header('content-type: text/plain');
$contents = file_get_contents('https://www.youtube.com/results?search_sort=video_date_uploaded&search_query=syria');
$contents = preg_replace('/\s(1,)/', ' ', $contents);
print $contents . "\n";
// if ($contents === false)
// print 'False';
// print_r($contents);
$records = $preg_split('/<h3 class="yt/', $contents);
for ($ix = 1; $ix < count($records); $ix++) (
$tmp = $records[$ix]
preg_match('/href="(.*?)"/', $tmp, $match_url);
print_r($match_url);
exit();
)