魏长东

weichangdong

东邪

simple_html_dom php操作html元素

<?php

include "simple_html_dom.php" ;
// Create DOM from URL or file
$html = file_get_html('http://www.google.com/');

// Find all images 
foreach($html->find('img') as $element) 
       echo $element->