SimpleXML
PHP Manual

The SimpleXMLElement class

(PHP 5, PHP 7)

简介

Represents an element in an XML document.

类摘要

SimpleXMLElement implements Traversable {
/* 方法 */
final public __construct ( string $data [, int $options = 0 [, bool $data_is_url = FALSE [, string $ns = "" [, bool $is_prefix = FALSE ]]]] )
public void addAttribute ( string $name [, string $value [, string $namespace ]] )
public SimpleXMLElement addChild ( string $name [, string $value [, string $namespace ]] )
public mixed asXML ([ string $filename ] )
public SimpleXMLElement attributes ([ string $ns = NULL [, bool $is_prefix = FALSE ]] )
public SimpleXMLElement children ([ string $ns [, bool $is_prefix = FALSE ]] )
public int count ( void )
public array getDocNamespaces ([ bool $recursive = FALSE [, bool $from_root = TRUE ]] )
public string getName ( void )
public array getNamespaces ([ bool $recursive = FALSE ] )
public bool registerXPathNamespace ( string $prefix , string $ns )
public string __toString ( void )
public array xpath ( string $path )
}

Table of Contents


SimpleXML
PHP Manual