Hi,
I am trying to get commented strings in my code using regular expression in php.
Let's say I have following string.
$string = "
///<summary>
///test
///</summary>
";
I use preg_match_all for regular expression function.
when I put $string to preg_match_all, it displays
Warning: preg_match() [function.preg-match]: Unknown modifier 'string' in /home/document/public_html/test.php on line 10
I guess it is because I have modifiers(/) in $string.
How do I get around this?
Actual Code
$string = "
///<summary
///aaa
///</summary>
";
$pattern = "/\/\/\/<summary>\/\/\/.*\/\/\/</summary";
preg_match($pattern,$a,$match);