You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+26-1
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,11 @@ Instead of having a hard-coded list of all the different microformats, it follow
10
10
11
11
There are two ways of installing php-mf2. I **highly recommend** installing php-mf2 using [Composer](http://getcomposer.org). The rest of the documentation assumes that you have done so.
12
12
13
-
To install using Composer, run `./composer.phar require mf2/mf2:~0.3`
13
+
To install using Composer, run
14
+
15
+
```
16
+
composer require mf2/mf2
17
+
```
14
18
15
19
If you can’t or don’t want to use Composer, then php-mf2 can be installed the old way by downloading [`/Mf2/Parser.php`](https://raw.githubusercontent.com/indieweb/php-mf2/master/Mf2/Parser.php), adding it to your project and requiring it from files you want to call its functions from, like this:
16
20
@@ -23,6 +27,15 @@ require_once 'Mf2/Parser.php';
23
27
$mf = Mf2\fetch('https://waterpigs.co.uk');
24
28
```
25
29
30
+
It is recommended to install the HTML5 parser for proper handling of HTML5 elements. Using composer, run
31
+
32
+
```
33
+
composer require masterminds/html5
34
+
```
35
+
36
+
If this library is added to your project, the php-mf2 parser will use it automatically instead of the built-in HTML parser.
37
+
38
+
26
39
### Signed Code Verification
27
40
28
41
From v0.2.9, php-mf2’s version tags are signed using GPG, allowing you to cryptographically verify that you’re using code which hasn’t been tampered with. To verify the code you will need the GPG keys for one of the people in the list of code signers:
@@ -342,6 +355,18 @@ Currently php-mf2 passes the majority of it’s own test case, and a good percen
342
355
343
356
### Changelog
344
357
358
+
#### v0.4.3
359
+
360
+
2018-03-29
361
+
362
+
If the [masterminds/html5](https://github.com/Masterminds/html5-php) HTML5 parser is available, the Mf2 parser will use that instead of the built-in HTML parser. This enables proper handling of HTML5 elements such as `<article>`.
0 commit comments