PHP Class Rss2

Author:
显示文件 Open project: zblogcn/zblogphp Class Usage Examples

Public Methods

Method Description
__construct ( string $title, string $link, string $description ) 构造函数,初始化RSS文档开头部分
addItem ( $title, $link, $description, $date ) 添加文章节点
createElement ( $name, $value ) : string 构造元素节点
saveXML ( ) : string 返回xml格式的RSS文档

Method Details

__construct() public method

构造函数,初始化RSS文档开头部分
public __construct ( string $title, string $link, string $description )
$title string
$link string
$description string

addItem() public method

添加文章节点
public addItem ( $title, $link, $description, $date )
$title
$link
$description
$date

createElement() public method

构造元素节点
public createElement ( $name, $value ) : string
$name
$value
return string

saveXML() public method

返回xml格式的RSS文档
public saveXML ( ) : string
return string