- 论坛徽章:
- 0
|
好像不行呀,
语法错误
<?php
$str="
<a href=\"http://www.163.com/news/rgh248/page12326.htm\"><img src=\"1.jpg\" width=\"90\" height=\"67\" border=\"1\"></a>
<a href=\"http://www.163.com/news/rgh2343242/page126.htm\"><img src=\"2.jpg\" width=\"90\" height=\"67\" border=\"1\"></a>
<a href=\"http://www.yahoo.com/aws/pa6.htm\"><img src=\"3.jpg\" width=\"90\" height=\"67\" border=\"1\"></a>";
preg_match_all("http://www.163.com/[^"]+",$str,$matches);
print_r ($matches);
?>
PHP Parse error: syntax error, unexpected ']' in /test.php on line 7 |
|