Re: Using DOM textContent Property

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Tim Gustafson a écrit :

$Elements = $HTML->getElementsByTagName("*");

for ($X = 0; $X < $Elements->length; $X++) {
  ... SNIP ...
}

Why don't use the XPath ? <http://fr.php.net/manual/en/class.domxpath.php>
<http://fr.php.net/manual/en/domxpath.query.php>

This query fetch all a elements with no title attribute or empty title attribute : '//a[not(@title) or @title = ""]' ;


--
Mickaël Wolff aka Lupus Michaelis
http://lupusmic.org

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux