正好我也在做标签的解析,互相探讨一下 获取网页源码用file_get_contents($url)就可以了 url如果是要解析网址的话记得加上http:// 比如在输入框内输入http://www.baidu.com //以下代码保存为catch.php <?php if(isset($_POST["url"])) { $url=$_POST["url"]; $fcont=file_get_contents($url); if(eregi('<table(.*)table>',$fcont,$re)) echo "Yes"; else echo "No"; echo $re[0]; } else { ?> <form action="catch.php" method="post"> url:<input type="text" size=30 name="url"> <input type="submi
php获取网页源代码
最新推荐文章于 2022-01-23 11:20:04 发布