(PHP 5)

simplexml_import_dom --  Get a simplexml_element object from a DOM node.


object simplexml_element simplexml_import_dom ( domNode node)

This function takes a node of a DOM document and makes it into a SimpleXML node. This new object can then be used as a native SimpleXML element. If any errors occur, it returns FALSE.

Example 1. Import DOM

= new domDocument;
if (!
$dom) {
'Error while parsing the document';

$s = simplexml_import_dom($dom);

$s->book[0]->title; // blah

Sites of interest: Web Hosting : Reseller Hosting : Website Hosting : HTML Editor : Web Design Templates : Free Web Hosting : ASP code examples : PHP & MySQL Code Examples
  Copyright 2004 Evrsoft Developer Network. Privacy policy - Link to Us

Contact Evrsoft