HTML sanitizer, written in PHP, aiming to provide XSS-safe markup based on explicitly allowed tags, attributes and values.

Overview

TYPO3 HTML Sanitizer

ℹ️ Common safe HTML tags & attributes as given in \TYPO3\HtmlSanitizer\Builder\CommonBuilder still might be adjusted, extended or rearranged to more specific builders.

In a Nutshell

This typo3/html-sanitizer package aims to be a standalone component that can be used by any PHP-based project or library. Albeit it is released within the TYPO3 namespace, it is agnostic to specifics of TYPO3 CMS.

  • \TYPO3\HtmlSanitizer\Behavior contains declarative settings for a particular process for sanitizing HTML.
  • \TYPO3\HtmlSanitizer\Visitor\VisitorInterface (multiple different visitors can exist at the same time) are actually doing the work based on the declared Behavior. Visitors can modify nodes or mark them for deletion.
  • \TYPO3\HtmlSanitizer\Sanitizer can be considered as the working instance, invoking visitors, parsing and serializing HTML. In general this instance does not contain much logic on how to handle particular nodes, attributes or values
  • \TYPO3\HtmlSanitizer\Builder\BuilderInterface can be used to create multiple different builder instances - in terms of "presets" - which combine declaring a particular Behavior, initialization of VisitorInterface instances, and finally returning a ready-to-use Sanitizer instance

Installation

composer req typo3/html-sanitizer

Example & API

<?php
use TYPO3\HtmlSanitizer\Behavior;
use TYPO3\HtmlSanitizer\Sanitizer;
use TYPO3\HtmlSanitizer\Visitor\CommonVisitor;

require_once 'vendor/autoload.php';

$commonAttrs = [
    new Behavior\Attr('id'),
    new Behavior\Attr('class'),
    new Behavior\Attr('data-', Behavior\Attr::NAME_PREFIX),
];
$hrefAttr = (new Behavior\Attr('href'))
    ->addValues(new Behavior\RegExpAttrValue('#^https?://#'));

// attention: only `Behavior` implementation uses immutability
// (invoking `withFlags()` or `withTags()` returns new instance)
$behavior = (new Behavior())
    ->withFlags(Behavior::ENCODE_INVALID_TAG)
    ->withTags(
        (new Behavior\Tag('div', Behavior\Tag::ALLOW_CHILDREN))
            ->addAttrs(...$commonAttrs),
        (new Behavior\Tag('a', Behavior\Tag::ALLOW_CHILDREN))
            ->addAttrs($hrefAttr, ...$commonAttrs),
        (new Behavior\Tag('br'))
    );

$visitors = [new CommonVisitor($behavior)];
$sanitizer = new Sanitizer(...$visitors);

$html = <<< EOH
<div id="main">
    <a href="https://typo3.org/" data-type="url" wrong-attr="is-removed">TYPO3</a><br>
    (the <span>SPAN, SPAN, SPAN</span> tag shall be encoded to HTML entities)
</div>
EOH;

echo $sanitizer->sanitize($html);

will result in the following sanitized output

<div id="main">
    <a href="https://typo3.org/" data-type="url">TYPO3</a><br>
    (the &lt;span&gt;SPAN, SPAN, SPAN&lt;/span&gt; tag shall be encoded to HTML entities)
</div>

Behavior flags

  • Behavior::ENCODE_INVALID_TAG keeps invalid tags, but "disarms" them (see <span> in example)
  • Behavior::ENCODE_INVALID_ATTR keeps invalid attributes, but "disarms" the whole(!) tag
  • Behavior::REMOVE_UNEXPECTED_CHILDREN removes children for Tag entities that were created without explicitly using Tag::ALLOW_CHILDREN, but actually contained child nodes
  • Behavior::ALLOW_CUSTOM_ELEMENTS allow using custom elements (having a hyphen -) - however, it is suggested to explicitly name all known and allowed tags and avoid using this flag

License

In general the TYPO3 core is released under the GNU General Public License version 2 or any later version (GPL-2.0-or-later). In order to avoid licensing issues and incompatibilities this package is licenced under the MIT License. In case you duplicate or modify source code, credits are not required but really appreciated.

Security Contact

In case of finding additional security issues in the TYPO3 project or in this package in particular, please get in touch with the TYPO3 Security Team.

Comments
  • Figure tag is missing and source tag does not allow necessary attributes

    Figure tag is missing and source tag does not allow necessary attributes

    The source tag does not allow the needed attributes, but only the global ones. https://developer.mozilla.org/en-US/docs/Web/HTML/Element/source#attributes

    The figure tag is missing completely. https://developer.mozilla.org/en-US/docs/Web/HTML/Element#text_content https://developer.mozilla.org/en-US/docs/Web/HTML/Element/figure


    moderation side note by @ohader

    HTML-encoded <figure> tags (or others) are not a bug of the typo3/html-sanitizer library per se, but instead indicate potential misconfiguration during content rendering via Fluid templates or TypoScript instructions. It is important to understand the security impact in custom templates. The fact that "it worked before" does not mean it was properly protected against cross-site scripting.

    Find details at #23: Troubleshooting "broken markup after recent TYPO3 updates"

    question typo3-cms 
    opened by kevin-appelt 20
  • Add XMPP URI support (RFC5122)

    Add XMPP URI support (RFC5122)

    Dear @TYPO3, @TYPO3GmbH teams,

    In first, I wish you a Happy New Year 2022!

    Can you see for add XMPP URI support? -> XMPP URI support must be added because there actually a problem, it is detected "mailto".

    Examples:

    It is a standard:

    • RFC5122: https://tools.ietf.org/html/rfc5122

    Thanks in advance.

    enhancement 
    opened by Neustradamus 7
  • Links split up and rendered wrong with images and short texts

    Links split up and rendered wrong with images and short texts

    Hey, I'm having issues with TYPO3 HTML rendering in version 10. Every time there is an image inside a href with little text, it splits them apart, thus destroying the link:

    Original

    <p>TITLE <em>ITALIC TEXT</em> basic text
    <a href="PDF_LINK">→<img alt="" data-htmlarea-file-uid="1787699" src="pdf_icon.png" /></a>
    </p>
    

    f:format.html output

    <p>TITLE <em>ITALIC TEXT</em> basic text
    <a href="PDF_LINK" target="_blank"></a>
    </p>
    <p>→<img src="pdf_icon.png"></p>
    

    I tried Slack and also read this chain of issues (https://github.com/TYPO3/html-sanitizer/issues/23), but the problem still persists.

    I can swap to raw, as there are typo3 internal links, that have to be rendered, and all the possible solutions either swapped to raw and broke internal links, or did nothing.

    I'm running TYPO3 v10.4.20 with html-sanitizer v2.0.9 It's also a fresh update from v9.

    question 
    opened by aaxc 7
  • Allow adding allowed values to existing attributes

    Allow adding allowed values to existing attributes

    I've come to code where custom onclick is added to a-Tags. TYPO3 already ads an onclick to allow list for a-Tags.

    I could not find any way to add another allowed value to the list. Looks like the code is too robust to allow me to add or alter the already configured behaviour. I only could remove the already build a-Tag and build it from scratch / from reading original values excluding the onclick and rebuilding it again? Do I overlook something here? How should a developer use the library in such situation, where a framework already adds configuration?

    That's our code which is just not called, because TYPO3 onclick value already does not match. Further values are not checked anymore. I couldn't find a way to check whether at least one value matches.

    class DefaultSanitizerBuilder extends Typo3DefaultSanitizerBuilder
    {
        protected function createBasicTags(): array
        {
            $tags = parent::createBasicTags();
            // Allow onlick="econdaTrackMarker();" in addition to TYPO3 native onclick code.
            $tags['a']->getAttr('onclick')->addValues(new RegExpAttrValue('#^econdaTrackMarker\(#'));
            return $tags;
        }
    }
    
    enhancement 
    opened by DanielSiepmann 6
  • center-tag missing, too

    center-tag missing, too

    Hi, I had the same issue as #23 with

    : all Text and content with Center-Tag around comes out in visible brackets. We found out late because it was in the newsletter-archive. htmlSanitize = 0 is working: page.stdWrap.parseFunc.htmlSanitize = 0 The Problem appeared in 10.4.21 with the best regards, Sabine

    opened by zabinetta 4
  • TYPO3 HTML Element doesn't work anymore

    TYPO3 HTML Element doesn't work anymore

    The TYPO3 standard HTML content element uses <f:format.raw>{data.bodytext}</f:format.raw> .

    We have inserted iframes like this: <iframe id="auto-iframe" name="auto-iframe" src="https://lademap.ladenetz.de/?lat=48.3434118&amp;lng=10.8921117&amp;zoom=12&amp;mode=1&amp;ivin=09ut249ugn9854h8bffd43" scrolling="no" onload="AutoiFrameAdjustiFrameHeight('auto-iframe',50);" width="100%" height="650px" frameborder="0"></iframe>

    But since last T3 update it is shown plain in FE.

    I tried:

    page.10.stdWrap.parseFunc {
        // replace --- with soft-hyphen
        short.--- = &shy;
        // sanitization of ALL MARKUP is NOT DESIRED here
        htmlSanitize = 0
      }
    
    // either disable globally
    lib.parseFunc.htmlSanitize = 0
    lib.parseFunc_RTE.htmlSanitize = 0
    

    But it ist not fixed. Could you please tell me how to get it work now without htmlSanitze?

    Yours, mike

    opened by intertain 4
  • Add different protocols for href such as webcal or ftp

    Add different protocols for href such as webcal or ftp

    I use links like webcal://domain.tld/calendar/ics for having the OS open a calendar app like Apple Calendar and offer the calendar subscription dialogue. For those links the href gets stripped from the output HTML.

    It would be great to add various other common protocols like e.g. webcal, ftp, file or at least offer a simple configuration method to add these to a website instead of having to add a complicated PHP class (not to mention that at this point in time I have found a tutorial on how to allow additional tags and attributes, but not a different link protocol).

    enhancement 
    opened by clivebeckett 3
  • Add support for [type], [start] and [reversed] attributes for the ol tag

    Add support for [type], [start] and [reversed] attributes for the ol tag

    Hi,

    we use the ordered bullet lists on our site, I know we can use the CSS "list-style-type" property to do the equivalent but for accessibility needs we have to use the [type], [start] and [reversed] attributes.

    https://developer.mozilla.org/en-US/docs/Web/HTML/Element/ol

    Thank you

    enhancement 
    opened by YanickRoss 3
  •  RSS Feed: Opening and ending tag mismatch: br

    RSS Feed: Opening and ending tag mismatch: br

    XML requires that all tags be closed. htmlSanitizer will output the br Tag as <br> instead of <br />

    TypoScript Workaround:

    rssfeed = PAGE
    rssfeed {
      typeNum = 100
      ...
      stdWrap {
        replacement
          10 {
            search = <br>
            replace = <br />
          }
        }
      }
    }
    
    question 
    opened by Andreas-Sommer-TUM 3
  • [TASK] Let test suite fail with E_ALL

    [TASK] Let test suite fail with E_ALL

    error_reporting default is E_ALL & ~E_DEPRECATED & ~E_STRICT. In general, we should strive for E_ALL error free tests: This helps to find issues with younger PHP versions more quickly.

    opened by lolli42 2
  • iframe tags inside rte content are broken

    iframe tags inside rte content are broken

    after Typo3 update to 10.4.19 or above all inserted iframes inside RTE content are broken.

    In our yaml config we explicity allow iframe tags with extraAllowedContent: 'iframe[*]{*}' inside RTE content.

    duplicate typo3-cms 
    opened by abohntek 2
  • [FEATURE] Add possibility to declare and apply presets to behavior

    [FEATURE] Add possibility to declare and apply presets to behavior

    Example (uses preset declaring <iframe> and applies it):

    use TYPO3\HtmlSanitizer\Behavior;
    use TYPO3\HtmlSanitizer\Builder\Preset\IframePreset;
    
    $behavior = (new Behavior())
        ->withFlags(Behavior::ENCODE_INVALID_TAG | Behavior::REMOVE_UNEXPECTED_CHILDREN)
        ->withName('scenario-test')
        ->withPreset(new IframePreset());
    

    Related: #91

    opened by ohader 1
  • Add possibility to declare and apply presets to behavior

    Add possibility to declare and apply presets to behavior

    use TYPO3\HtmlSanitizer\Behavior;
    use TYPO3\HtmlSanitizer\Builder\Preset\IframePreset;
    
    $behavior = (new Behavior())
        ->withFlags(Behavior::ENCODE_INVALID_TAG | Behavior::REMOVE_UNEXPECTED_CHILDREN)
        ->withName('scenario-test')
        ->withPreset(new IframePreset());
    
    enhancement 
    opened by ohader 0
  • ALLOW_CHILDREN and PURGE_WITHOUT_ATTRS can't be set at the same time

    ALLOW_CHILDREN and PURGE_WITHOUT_ATTRS can't be set at the same time

    I want to use a certain tag that should be allowed to have children. In this case I'd use ALLOW_CHILDREN as a flag on my new tag.

    But what if I want to allow it only if it has a specific attribute on it, like a must-have attribute?

    I can't give it both flags, only one. So I have to decide whether it shows its content or shows itself if it has an attribute, but then it doesn't render the content inside of it.

    Also, what is it with PURGE_WITHOUT_CHILDREN? This can't be used since you'd have to allow children in the first place. If I use this flag, I get "Tag %s does not allow children, but shall be purged without them", what's the point of setting this flag then?

    bug enhancement 
    opened by darthnorman 3
  • iFrame is escaped in output and not working anymore

    iFrame is escaped in output and not working anymore

    Since some versions there is a problem that iFrames are escaped in the output and the iframe is not visible. Before 10.4.18 i think it was working fine. Not the problem is that the youtube plugin for the RTE isn't working anymore.

    Version is 10.4.21 (Composer latest version)

    <p>&lt;iframe allowfullscreen frameborder="0" height="360"
      src="https://www.youtube.com/embed/fUEHlY8" width="640"&gt;&lt;/iframe&gt;</p>
    

    So i have checked not a lot of tutorials and tested now over 2 hours all solutions.

    In the Site TS-Config i have tested a low of things.

    RTE.default.proc {
      allowTags := addToList(object,param,embed,iframe)
      allowTagsOutside := addToList(object,embed,iframe)
      entryHTMLparser_db.allowTags < .allowTags
    }
    

    But nothing is working anymore. Is there a solution or a fix to solve the Problem? Do i miss something?

    enhancement 
    opened by rehoehle 4
  • Separate markup declarations between living standard and deprecations

    Separate markup declarations between living standard and deprecations

    To keep track of using deprecated markup, tags, attributes, a new flag shall be introduced that reflects this deprecated state.

    Valid for these objects:

    • Behavior\Tag
    • Behavior\Attr
    enhancement 
    opened by ohader 0
Releases(v2.1.1)
  • v2.1.1(Dec 13, 2022)

    What's Changed

    • [TASK] CI: Remove workaround for phpspec/prophecy and PHP 8.2 by @andreasfernandez in https://github.com/TYPO3/html-sanitizer/pull/104
    • [SECURITY] Mitigate XSS in CDATA and HTML raw text elements by @ohader in https://github.com/TYPO3/html-sanitizer/pull/105

    Full Changelog: https://github.com/TYPO3/html-sanitizer/compare/v2.1.0...v2.1.1

    Source code(tar.gz)
    Source code(zip)
  • v1.5.0(Dec 13, 2022)

    What's Changed

    • [TASK] Backport library to support PHP 7.0 and 7.1 by @andreasfernandez in https://github.com/TYPO3/html-sanitizer/pull/103
    • [SECURITY] Mitigate XSS in CDATA and HTML raw text elements by @ohader in https://github.com/TYPO3/html-sanitizer/pull/106

    Full Changelog: https://github.com/TYPO3/html-sanitizer/compare/v2.1.0...v1.5.0

    Source code(tar.gz)
    Source code(zip)
  • v2.1.0(Dec 5, 2022)

    What's Changed

    • [FEATURE] Introduce mandatory tag attributes by @ohader in https://github.com/TYPO3/html-sanitizer/pull/74
    • [FEATURE] Introduce Behavior\EmptyAttrValue by @ohader in https://github.com/TYPO3/html-sanitizer/pull/88
    • [!!!][TASK] Rename variable $node to $domNode by @ohader in https://github.com/TYPO3/html-sanitizer/pull/90
    • [FEATURE] Add possibility to control comments and CDATA sections by @ohader in https://github.com/TYPO3/html-sanitizer/pull/92
    • [FEATURE] Add possibility to handle nodes individually by @ohader in https://github.com/TYPO3/html-sanitizer/pull/95
    • [TASK] Update GitHub Actions workflow by @andreasfernandez in https://github.com/TYPO3/html-sanitizer/pull/96
    • [TASK] Streamline \TYPO3\HtmlSanitizer\Sanitizer by @ohader in https://github.com/TYPO3/html-sanitizer/pull/97
    • [!!!][FEATURE] Allow to use custom output rules by @ohader in https://github.com/TYPO3/html-sanitizer/pull/98
    • [TASK] Postpone Sanitizer deprecations by @ohader in https://github.com/TYPO3/html-sanitizer/pull/100

    Full Changelog: https://github.com/TYPO3/html-sanitizer/compare/v2.0.16...v2.1.0

    Source code(tar.gz)
    Source code(zip)
  • v2.0.16(Sep 13, 2022)

    What's Changed

    • [TASK] Allow CI for any branch, add schedule, add badge by @lolli42 in https://github.com/TYPO3/html-sanitizer/pull/84
    • [TASK] Add PHP 8.2 to test matrix by @lolli42 in https://github.com/TYPO3/html-sanitizer/pull/85
    • [TASK] Avoid phpunit cache file by @lolli42 in https://github.com/TYPO3/html-sanitizer/pull/83
    • [SECURITY] Correctly handle comment end bang state by @ohader in https://github.com/TYPO3/html-sanitizer/pull/86

    Full Changelog: https://github.com/TYPO3/html-sanitizer/compare/v2.0.15...v2.0.16

    Source code(tar.gz)
    Source code(zip)
  • v1.0.7(Sep 13, 2022)

    What's Changed

    • [TASK] Add Behavior\Attr tests by @ohader in https://github.com/TYPO3/html-sanitizer/pull/54
    • [SECURITY] Correctly handle comment end bang state by @ohader in https://github.com/TYPO3/html-sanitizer/pull/87

    Full Changelog: https://github.com/TYPO3/html-sanitizer/compare/v1.0.6...v1.0.7

    Source code(tar.gz)
    Source code(zip)
  • v2.0.15(Jul 27, 2022)

    What's Changed

    • [TASK] add img attr. fetchPriority by @xerc in https://github.com/TYPO3/html-sanitizer/pull/81
    • [BUGFIX] lowercase track attr. srclang by @xerc in https://github.com/TYPO3/html-sanitizer/pull/80
    • [TASK] Allow additional URI schemes afp, smb, vnc, xmpp by @ohader in https://github.com/TYPO3/html-sanitizer/pull/82

    New Contributors

    • @xerc made their first contribution in https://github.com/TYPO3/html-sanitizer/pull/81

    Full Changelog: https://github.com/TYPO3/html-sanitizer/compare/v2.0.14...v2.0.15

    Source code(tar.gz)
    Source code(zip)
  • v2.0.14(Feb 21, 2022)

    What's Changed

    • [TASK] Run tests with PHP 8.1 by @lolli42 in https://github.com/TYPO3/html-sanitizer/pull/67
    • [TASK] Let test suite fail with E_ALL by @lolli42 in https://github.com/TYPO3/html-sanitizer/pull/68
    • [TASK] Ensure error_reporting uses E_ALL by @ohader in https://github.com/TYPO3/html-sanitizer/pull/72
    • [BUGFIX] Purge node only having empty text nodes by @ohader in https://github.com/TYPO3/html-sanitizer/pull/73
    • [TASK] Allow installation of any PSR-Log version. by @Crell in https://github.com/TYPO3/html-sanitizer/pull/78

    Full Changelog: https://github.com/TYPO3/html-sanitizer/compare/v2.0.13...v2.0.14

    Source code(tar.gz)
    Source code(zip)
  • v2.0.13(Oct 12, 2021)

  • v2.0.12(Oct 12, 2021)

  • v2.0.11(Sep 21, 2021)

    2d6f518 [TASK] Allow more URI schemes for href attribute 8d8097f [TASK] Add immutable behavior to Behavior\Attr d8bcac6 [FEATURE] Allow data URI for media types 2828be4 [TASK] Introduce UriAttrValueBuilder b0322ad [TASK] Allow ol and li attributes 7a74225 [TASK] Allow RFC 2392 compliant URI schemes b205c1e [TASK] Add Behavior\Attr tests

    Source code(tar.gz)
    Source code(zip)
  • v2.0.10(Aug 25, 2021)

    • b9267c3 [TASK] Adjust PHPDoc comments & code clean-up
    • 200728d [TASK] Adjust internal variable names
    • fb33578 [TASK] Allow font tag (deprecated)
    Source code(tar.gz)
    Source code(zip)
  • v1.0.6(Aug 25, 2021)

    • 2b14b1f [TASK] Adjust PHPDoc comments & code clean-up
    • bb40e7f [TASK] Adjust internal variable names
    • 7ea2bbd [TASK] Allow font tag (deprecated)
    Source code(tar.gz)
    Source code(zip)
  • v2.0.9(Aug 16, 2021)

    • 5dfd055 [TASK] Adjust README.md
    • 2abedaa [TASK] Extend README.md
    • 2fb9e71 [TASK] Allow using microdata meta data
    • 7f0af1e [TASK] Extend image tag attributes
    • d22b74c [TASK] Replace overlint with native linting
    Source code(tar.gz)
    Source code(zip)
  • v1.0.5(Aug 16, 2021)

    • df5838f [TASK] Adjust README.md
    • ef908e6 [TASK] Extend README.md
    • 8271dd9 [TASK] Allow using microdata meta data
    • ae56974 [TASK] Extend image tag attributes
    Source code(tar.gz)
    Source code(zip)
  • v2.0.8(Aug 12, 2021)

    • 8df823e [TASK] Add test cases for media related tags/attrs
    • 12d0894 [TASK] Add img.loading attribute
    • 01f3dee [TASK] Allow figure tag and necessary attributes in source tag
    • f6c1de1 [FEATURE] Forward sanitization initiator to logging
    • 82e1596 [TASK] Separate <table> declarations in own method
    • 06ec88b [TASK] Streamline media tag declarations
    • efce1b1 [BUGFIX] Add missing <table> related attributes
    Source code(tar.gz)
    Source code(zip)
  • v1.0.4(Aug 12, 2021)

  • v1.0.3(Aug 12, 2021)

    • 1ca48eb [TASK] Allow figure tag and necessary attributes in source tag
    • 16eeac4 [FEATURE] Forward sanitization initiator to logging
    • b15964b [BUGFIX] Add missing <table> related attributes
    Source code(tar.gz)
    Source code(zip)
  • v2.0.7(Aug 8, 2021)

  • v1.0.2(Aug 8, 2021)

  • v2.0.6(Jul 19, 2021)

  • v1.0.1(Jul 19, 2021)

  • v2.0.5(Jul 15, 2021)

Owner
TYPO3 GitHub Department
https://github.com/typo3-documentation https://github.com/FriendsOfTYPO3
TYPO3 GitHub Department
php html parser,类似与PHP Simple HTML DOM Parser,但是比它快好几倍

HtmlParser php html解析工具,类似与PHP Simple HTML DOM Parser。 由于基于php模块dom,所以在解析html时的效率比 PHP Simple HTML DOM Parser 快好几倍。 注意:html代码必须是utf-8编码字符,如果不是请转成utf-8

俊杰jerry 522 Dec 29, 2022
Convert HTML to Markdown with PHP

HTML To Markdown for PHP Library which converts HTML to Markdown for your sanity and convenience. Requires: PHP 7.2+ Lead Developer: @colinodell Origi

The League of Extraordinary Packages 1.5k Dec 28, 2022
📜 Modern Simple HTML DOM Parser for PHP

?? Simple Html Dom Parser for PHP A HTML DOM parser written in PHP - let you manipulate HTML in a very easy way! This is a fork of PHP Simple HTML DOM

Lars Moelleken 665 Jan 4, 2023
Highly-extensible PHP Markdown parser which fully supports the CommonMark and GFM specs.

league/commonmark league/commonmark is a highly-extensible PHP Markdown parser created by Colin O'Dell which supports the full CommonMark spec and Git

The League of Extraordinary Packages 2.4k Jan 1, 2023
An HTML5 parser and serializer for PHP.

HTML5-PHP HTML5 is a standards-compliant HTML5 parser and writer written entirely in PHP. It is stable and used in many production websites, and has w

null 1.2k Dec 31, 2022
Advanced shortcode (BBCode) parser and engine for PHP

Shortcode Shortcode is a framework agnostic PHP library allowing to find, extract and process text fragments called "shortcodes" or "BBCodes". Example

Tomasz Kowalczyk 358 Nov 26, 2022
UpToDocs scans a Markdown file for PHP code blocks, and executes each one in a separate process.

UpToDocs UpToDocs scans a Markdown file for PHP code blocks, and executes each one in a separate process. Include this in your CI workflows, to make s

Mathias Verraes 56 Nov 26, 2022
Efficient, easy-to-use, and fast PHP JSON stream parser

JSON Machine Very easy to use and memory efficient drop-in replacement for inefficient iteration of big JSON files or streams for PHP 5.6+. See TL;DR.

Filip Halaxa 801 Dec 28, 2022
A simple PHP scripting application which fetch emails from your Gmail account according to a filter and parses them for information.

A simple PHP scripting application which fetch emails from your Gmail account according to a filter and parses them for information.

Haitham Sweilem 1 Jan 18, 2022
Parser for Markdown and Markdown Extra derived from the original Markdown.pl by John Gruber.

PHP Markdown PHP Markdown Lib 1.9.0 - 1 Dec 2019 by Michel Fortin https://michelf.ca/ based on Markdown by John Gruber https://daringfireball.net/ Int

Michel Fortin 3.3k Jan 1, 2023
Plug and play flat file markdown blog for your Laravel-projects

Ampersand Plug-and-play flat file markdown blog tool for your Laravel-project. Create an article or blog-section on your site without the hassle of se

Marcus Olsson 22 Dec 5, 2022
Better Markdown Parser in PHP

Parsedown Better Markdown Parser in PHP - Demo. Features One File No Dependencies Super Fast Extensible GitHub flavored Tested in 5.3 to 7.3 Markdown

Emanuil Rusev 14.3k Jan 8, 2023
A super fast, highly extensible markdown parser for PHP

A super fast, highly extensible markdown parser for PHP What is this? A set of PHP classes, each representing a Markdown flavor, and a command line to

Carsten Brandt 989 Dec 16, 2022
A simple PHP library for handling Emoji

Emoji Emoji images from unicode characters and names (i.e. :sunrise:). Built to work with Twemoji images. use HeyUpdate\Emoji\Emoji; use HeyUpdate\Emo

null 54 May 23, 2022
A simple PHP library for handling Emoji

Emoji Emoji images from unicode characters and names (i.e. :sunrise:). Built to work with Twemoji images. use HeyUpdate\Emoji\Emoji; use HeyUpdate\Emo

null 51 Jan 15, 2021
Parsica - PHP Parser Combinators - The easiest way to build robust parsers.

Parsica The easiest way to build robust parsers in PHP.

null 0 Feb 22, 2022
A simple Atom/RSS parsing library for PHP.

SimplePie SimplePie is a very fast and easy-to-use class, written in PHP, that puts the 'simple' back into 'really simple syndication'. Flexible enoug

SimplePie 1.5k Dec 18, 2022
This is a simple php project to help a friend how parse a xml file.

xml-parser-with-laravie Requirements PHP 7.4+ Composer 2+ How to to setup to test? This is very simple, just follow this commands git clone https://gi

Lucas Saraiva 2 Dec 3, 2021
This is a php parser for plantuml source file.

PlantUML parser for PHP Overview This package builds AST of class definitions from plantuml files. This package works only with php. Installation Via

Tasuku Yamashita 5 May 29, 2022