PHP 클래스 simple_html_dom_node, vanilla

파일 보기 프로젝트 열기: vanilla/vanilla 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$_
$attr
$children
$nodes
$nodetype
$parent
$tag
$tag_start

공개 메소드들

메소드 설명
__construct ( $dom )
__destruct ( )
__get ( $name )
__isset ( $name )
__set ( $name, $value )
__toString ( )
__unset ( $name )
childNodes ( $idx )
children ( $idx ) returns children of node
clear ( ) clean up memory due to php5 circular references memory leak.
convert_text ( $text ) PaperG - Function to convert the text from one character set to another if the two sets are not the same.
dump ( $show_attr = true, $deep ) dump node's tree
dump_node ( ) Debugging function to dump a single dom node with a bunch of information about it.
find ( $selector, $idx = null, $lowercase = false ) PaperG - added ability for find to lowercase the value of the selector.
find_ancestor_tag ( $tag ) function to locate a specific ancestor tag in the path to the root.
firstChild ( )
first_child ( ) returns the first child of node
getAllAttributes ( ) camel naming conventions
getAttribute ( $name )
getElementById ( $id )
getElementByTagName ( $name )
getElementsById ( $id, $idx = null )
getElementsByTagName ( $name, $idx = null )
hasAttribute ( $name )
innertext ( ) get dom node's inner html
is_utf8 ( $string )
lastChild ( )
last_child ( ) returns the last child of node
makeup ( ) build node's text with tag
nextSibling ( )
next_sibling ( ) returns the next sibling of node
outertext ( ) get dom node's outer text (with tag)
parent ( ) returns the parent of node
parentNode ( )
prev_sibling ( ) returns the previous sibling of node
previousSibling ( )
removeAttribute ( $name )
setAttribute ( $name, $value )
text ( ) get dom node's plain text
xmltext ( )

보호된 메소드들

메소드 설명
match ( $exp, $pattern, $value )
parse_selector ( $selector_string )
seek ( $selector, &$ret, $lowercase = false ) PaperG - added parameter to allow for case insensitive testing of the value of a selector.

메소드 상세

__construct() 공개 메소드

public __construct ( $dom )

__destruct() 공개 메소드

public __destruct ( )

__get() 공개 메소드

public __get ( $name )

__isset() 공개 메소드

public __isset ( $name )

__set() 공개 메소드

public __set ( $name, $value )

__toString() 공개 메소드

public __toString ( )

__unset() 공개 메소드

public __unset ( $name )

childNodes() 공개 메소드

public childNodes ( $idx )

children() 공개 메소드

returns children of node
public children ( $idx )

clear() 공개 메소드

..
public clear ( )

convert_text() 공개 메소드

PaperG - Function to convert the text from one character set to another if the two sets are not the same.
public convert_text ( $text )

dump() 공개 메소드

dump node's tree
public dump ( $show_attr = true, $deep )

dump_node() 공개 메소드

Debugging function to dump a single dom node with a bunch of information about it.
public dump_node ( )

find() 공개 메소드

PaperG - added ability for find to lowercase the value of the selector.
public find ( $selector, $idx = null, $lowercase = false )

find_ancestor_tag() 공개 메소드

function to locate a specific ancestor tag in the path to the root.
public find_ancestor_tag ( $tag )

firstChild() 공개 메소드

public firstChild ( )

first_child() 공개 메소드

returns the first child of node
public first_child ( )

getAllAttributes() 공개 메소드

camel naming conventions
public getAllAttributes ( )

getAttribute() 공개 메소드

public getAttribute ( $name )

getElementById() 공개 메소드

public getElementById ( $id )

getElementByTagName() 공개 메소드

public getElementByTagName ( $name )

getElementsById() 공개 메소드

public getElementsById ( $id, $idx = null )

getElementsByTagName() 공개 메소드

public getElementsByTagName ( $name, $idx = null )

hasAttribute() 공개 메소드

public hasAttribute ( $name )

innertext() 공개 메소드

get dom node's inner html
public innertext ( )

is_utf8() 공개 메소드

public is_utf8 ( $string )

lastChild() 공개 메소드

public lastChild ( )

last_child() 공개 메소드

returns the last child of node
public last_child ( )

makeup() 공개 메소드

build node's text with tag
public makeup ( )

match() 보호된 메소드

protected match ( $exp, $pattern, $value )

nextSibling() 공개 메소드

public nextSibling ( )

next_sibling() 공개 메소드

returns the next sibling of node
public next_sibling ( )

outertext() 공개 메소드

get dom node's outer text (with tag)
public outertext ( )

parent() 공개 메소드

returns the parent of node
public parent ( )

parentNode() 공개 메소드

public parentNode ( )

parse_selector() 보호된 메소드

protected parse_selector ( $selector_string )

prev_sibling() 공개 메소드

returns the previous sibling of node
public prev_sibling ( )

previousSibling() 공개 메소드

public previousSibling ( )

removeAttribute() 공개 메소드

public removeAttribute ( $name )

seek() 보호된 메소드

PaperG - added parameter to allow for case insensitive testing of the value of a selector.
protected seek ( $selector, &$ret, $lowercase = false )

setAttribute() 공개 메소드

public setAttribute ( $name, $value )

text() 공개 메소드

get dom node's plain text
public text ( )

xmltext() 공개 메소드

public xmltext ( )

프로퍼티 상세

$_ 공개적으로 프로퍼티

public $_

$attr 공개적으로 프로퍼티

public $attr

$children 공개적으로 프로퍼티

public $children

$nodes 공개적으로 프로퍼티

public $nodes

$nodetype 공개적으로 프로퍼티

public $nodetype

$parent 공개적으로 프로퍼티

public $parent

$tag 공개적으로 프로퍼티

public $tag

$tag_start 공개적으로 프로퍼티

public $tag_start