关于PHP正则表达式提取远程页面中的Table内容解决方法

WBOY
Release: 2016-06-13 13:27:05
Original
1086 people have browsed it

关于PHP正则表达式提取远程页面中的Table内容
想提取远程指定url中的table所有内容(包括html代码),使用PHP正则表达式应该如何写?
例如需要提取该页面中table所有的内容:http://www.tzga.gov.cn:6080/wscgs/vio.do?act=veh_vio_query

------解决方案--------------------

PHP code
$s=file_get_contents('http://www.tzga.gov.cn:6080/wscgs/vio.do?act=veh_vio_query');
preg_match_all('/
Copy after login
]+>(.*)/isU',$s,$m); print_r($m[1]);
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!