Php 纯javascript的simplehtmldom刮分页
我正在练习使用simplehtmldom,但是我遇到了一个小问题,我计划练习的站点上的分页只是javascript,当我关闭javascript时,它会中断分页,因此根本不会显示()。这是我目前的代码:Php 纯javascript的simplehtmldom刮分页,php,parsing,Php,Parsing,我正在练习使用simplehtmldom,但是我遇到了一个小问题,我计划练习的站点上的分页只是javascript,当我关闭javascript时,它会中断分页,因此根本不会显示()。这是我目前的代码: <?php include('simple_html_dom.php'); // Create DOM from URL $html = file_get_html('http://www.asus.com/Motherboards/Intel_Platform_Products/
<?php
include('simple_html_dom.php');
// Create DOM from URL
$html = file_get_html('http://www.asus.com/Motherboards/Intel_Platform_Products/');
// Find all article blocks
foreach($html->find('.hot-product-unit') as $article) {
$item['title'] = $article->find('.productslogan', 0)->plaintext;
$articles[] = $item;
echo "hello";
sleep(1);
}
print_r($articles);
?>
这个问题还导致整个代码中断,因为当没有javascript时,站点也不会显示产品列表
我该如何解决这个问题
谢谢你的帮助,
马库斯