diff --git a/CHANGELOG.md b/CHANGELOG.md index 7f4e6cf0..43b5373d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,7 @@ This is the changelog between releases of PHPWord. Releases are listed in revers ## 0.11.0 - Not yet released -This release marked the change of PHPWord license from LGPL 2.1 to LGPL 3. Four new elements were added: TextBox, ListItemRun, Field, and Line. Relative and absolute positioning for images and textboxes were added. Writer classes were refactored into parts, elements, and styles. ODT and RTF features were enhanced. Ability to add elements to PHPWord object via HTML were implemeted. RTF reader were initiated. +This release marked the change of PHPWord license from LGPL 2.1 to LGPL 3. Four new elements were added: TextBox, ListItemRun, Field, and Line. Relative and absolute positioning for images and textboxes were added. Writer classes were refactored into parts, elements, and styles. ODT and RTF features were enhanced. Ability to add elements to PHPWord object via HTML were implemeted. RTF and HTML reader were initiated. ### Features @@ -33,6 +33,7 @@ This release marked the change of PHPWord license from LGPL 2.1 to LGPL 3. Four - RTF Reader: Basic RTF reader - @ivanlanin GH-72 GH-252 - Element: New `Line` element - @basjan GH-253 - Title: Ability to apply numbering in heading - @ivanlanin GH-193 +- HTML Reader: Basic HTML reader - @ivanlanin GH-80 GH-254 ### Bugfixes diff --git a/docs/intro.rst b/docs/intro.rst index 3da729e8..94001237 100644 --- a/docs/intro.rst +++ b/docs/intro.rst @@ -117,61 +117,61 @@ Writers Readers ~~~~~~~ -+---------------------------+----------------------+--------+-------+-------+ -| Features | | DOCX | ODT | RTF | -+===========================+======================+========+=======+=======+ -| **Document Properties** | Standard | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Custom | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| **Element Type** | Text | ✓ | ✓ | ✓ | -+---------------------------+----------------------+--------+-------+-------+ -| | Text Run | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Title | ✓ | ✓ | | -+---------------------------+----------------------+--------+-------+-------+ -| | Link | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Preserve Text | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Text Break | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Page Break | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | List | ✓ | ✓ | | -+---------------------------+----------------------+--------+-------+-------+ -| | Table | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Image | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Object | | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Watermark | | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Table of Contents | | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Header | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Footer | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Footnote | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Endnote | ✓ | | | -+---------------------------+----------------------+--------+-------+-------+ -| **Graphs** | 2D basic graphs | | | | -+---------------------------+----------------------+--------+-------+-------+ -| | 2D advanced graphs | | | | -+---------------------------+----------------------+--------+-------+-------+ -| | 3D graphs | | | | -+---------------------------+----------------------+--------+-------+-------+ -| **Math** | OMML support | | | | -+---------------------------+----------------------+--------+-------+-------+ -| | MathML support | | | | -+---------------------------+----------------------+--------+-------+-------+ -| **Bonus** | Encryption | | | | -+---------------------------+----------------------+--------+-------+-------+ -| | Protection | | | | -+---------------------------+----------------------+--------+-------+-------+ ++---------------------------+----------------------+--------+-------+-------+-------+ +| Features | | DOCX | ODT | RTF | HTML | ++===========================+======================+========+=======+=======+=======+ +| **Document Properties** | Standard | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Custom | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| **Element Type** | Text | ✓ | ✓ | ✓ | ✓ | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Text Run | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Title | ✓ | ✓ | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Link | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Preserve Text | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Text Break | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Page Break | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | List | ✓ | ✓ | | ✓ | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Table | ✓ | | | ✓ | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Image | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Object | | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Watermark | | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Table of Contents | | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Header | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Footer | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Footnote | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Endnote | ✓ | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| **Graphs** | 2D basic graphs | | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | 2D advanced graphs | | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | 3D graphs | | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| **Math** | OMML support | | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | MathML support | | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| **Bonus** | Encryption | | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ +| | Protection | | | | | ++---------------------------+----------------------+--------+-------+-------+-------+ Contributing ------------ diff --git a/docs/src/documentation.md b/docs/src/documentation.md index 9db32c9f..773269a9 100644 --- a/docs/src/documentation.md +++ b/docs/src/documentation.md @@ -111,34 +111,34 @@ Below are the supported features for each file formats. ### Readers -| Features | | DOCX | ODT | RTF | -|-------------------------|--------------------|------|-----|-----| -| **Document Properties** | Standard | ✓ | | | -| | Custom | ✓ | | | -| **Element Type** | Text | ✓ | ✓ | ✓ | -| | Text Run | ✓ | | | -| | Title | ✓ | ✓ | | -| | Link | ✓ | | | -| | Preserve Text | ✓ | | | -| | Text Break | ✓ | | | -| | Page Break | ✓ | | | -| | List | ✓ | ✓ | | -| | Table | ✓ | | | -| | Image | ✓ | | | -| | Object | | | | -| | Watermark | | | | -| | Table of Contents | | | | -| | Header | ✓ | | | -| | Footer | ✓ | | | -| | Footnote | ✓ | | | -| | Endnote | ✓ | | | -| **Graphs** | 2D basic graphs | | | | -| | 2D advanced graphs | | | | -| | 3D graphs | | | | -| **Math** | OMML support | | | | -| | MathML support | | | | -| **Bonus** | Encryption | | | | -| | Protection | | | | +| Features | | DOCX | ODT | RTF | HTML| +|-------------------------|--------------------|------|-----|-----|-----| +| **Document Properties** | Standard | ✓ | | | | +| | Custom | ✓ | | | | +| **Element Type** | Text | ✓ | ✓ | ✓ | ✓ | +| | Text Run | ✓ | | | | +| | Title | ✓ | ✓ | | | +| | Link | ✓ | | | | +| | Preserve Text | ✓ | | | | +| | Text Break | ✓ | | | | +| | Page Break | ✓ | | | | +| | List | ✓ | ✓ | | ✓ | +| | Table | ✓ | | | ✓ | +| | Image | ✓ | | | | +| | Object | | | | | +| | Watermark | | | | | +| | Table of Contents | | | | | +| | Header | ✓ | | | | +| | Footer | ✓ | | | | +| | Footnote | ✓ | | | | +| | Endnote | ✓ | | | | +| **Graphs** | 2D basic graphs | | | | | +| | 2D advanced graphs | | | | | +| | 3D graphs | | | | | +| **Math** | OMML support | | | | | +| | MathML support | | | | | +| **Bonus** | Encryption | | | | | +| | Protection | | | | | ## Contributing diff --git a/samples/Sample_26_Html.php b/samples/Sample_26_Html.php index 58436915..92b3aa49 100644 --- a/samples/Sample_26_Html.php +++ b/samples/Sample_26_Html.php @@ -8,7 +8,11 @@ $phpWord = new \PhpOffice\PhpWord\PhpWord(); $section = $phpWord->addSection(); $html = '
Some well formed HTML snippet needs to be used
'; -$html .= 'With for example some inline formatting
'; +$html .= 'With for example some1 inline formatting1
'; +$html .= 'Unordered (bulleted) list:
'; +$html .= 'Ordered (numbered) list:
'; +$html .= 'Some well formed HTML snippet needs to be used
+With for example some1 inline formatting1
+Unordered (bulleted) list:
+Ordered (numbered) list:
+