Skip to content

Commit 3ac3fa4

Browse files
committed
usage examples added into readme
1 parent 15b35c2 commit 3ac3fa4

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

README.md

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,26 @@ Extract contents from HTML in a single line.
1313

1414
http://simplehtmldom.sourceforge.net/
1515

16+
17+
Install
18+
-------
19+
20+
composer.phar require
21+
- package name: "sunra/php-simple-html-dom-parser": "dev-master"
22+
23+
24+
Usage
25+
-----
26+
27+
'''php
28+
use Sunra\PhpSimple\HtmlDomParser;
29+
30+
...
31+
$dom = HtmlDomParser::str_get_html( $str );
32+
or
33+
$dom = HtmlDomParser::file_get_html( $file_name );
34+
35+
$elems = $dom->find($elem_name);
36+
...
37+
38+
'''

0 commit comments

Comments
 (0)