i want to check the script tag in an url
For example: if url have the script tag the below senario is working fine..
<?php
$url = 'admin/content/test/<script>';
preg_match('<script>', $url, $match);
if (count($match) >= 1) {
print 'It executes';
}
?>
output: It executes
but in my case if the url have a string "product_description" then also above condition matches
<?php
$url = 'admin/content/product_description/test';
preg_match('<script>', $url, $match);
if (count($match) >= 1) {
print 'It executes';
}
?>
output: It executes
Please suggest the right way to check the script tag in an url..