Answer the question
In order to leave comments, you need to log in
How to fix syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ')'?
Help fix syntax error:
Browser gives:
Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING, expecting ')'
if(preg_match("/http:\/\/vk.com|http:\/\/www.vk.com/i", $video_lnk)){
$rEXPVK = explode('<img id="player_thumb" src="', $html);
$rEXPVK_2 = explode('"', $rEXPVK[1]);
$rEXPVK_3 = explode('var video_title = \'', $html);
$rEXPVK_4 = explode("'", $rEXPVK_3[1]);
$rEXPVK_4[0] = urldecode($rEXPVK_4[0]);
$res_img = $rEXPVK_2[0];
$result_title = $rEXPVK_4[0];
if(!$result_title) $result_title = 'No name';
}
$result_img = $res_img;
if(!preg_match("/http:\/\/vk.com|http:\/\/www.vk.com/i", $video_lnk));
$result_title = trim(strip_tags(strtr($res_title, array(''' => "'", '"' => '"', '&iqu;' => '[', '&iqu2;' => ']')));
else
$result_title = trim(strip_tags($result_title));
$result_descr = trim(strip_tags($res_descr));
if($result_img && $result_title)
echo "{$result_img}:|:{$result_title}:|:{$result_descr}";
else
echo 'no_serviece';
}
} else
echo 'no_serviece';
die();
break;
$result_title = trim(strip_tags(strtr($res_title, array(''' => "'", '"' => '"', '&iqu;' => '[', '&iqu2;' => ']'))));
Answer the question
In order to leave comments, you need to log in
Mama-ama, crime
Forgot to escape the quote.
That's why they say - do not type in a notepad, scribble in normal editors with highlighting.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question