From c47ec883dc4369d59dd45dd1109a301e62b7f19f Mon Sep 17 00:00:00 2001 From: Jakub Zalas Date: Tue, 12 May 2015 17:32:06 +0100 Subject: [PATCH 1/2] [DomCrawler] Warn users of older PHP versions Crawler might not decode html entities properly. --- components/dom_crawler.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/components/dom_crawler.rst b/components/dom_crawler.rst index 4a4da289d4f..55b7a55be45 100644 --- a/components/dom_crawler.rst +++ b/components/dom_crawler.rst @@ -231,6 +231,7 @@ and :phpclass:`DOMNode` objects: $html = $crawler->html(); The ``html`` method is new in Symfony 2.3. + In PHP < 5.3.6 it might return html entities which are not properly decoded. Links ~~~~~ From 699e63740374ff53c8a53e0a5828ab0d08a45827 Mon Sep 17 00:00:00 2001 From: Javier Eguiluz Date: Wed, 24 Jun 2015 10:01:20 +0200 Subject: [PATCH 2/2] Reworded the notice as a caution --- components/dom_crawler.rst | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/components/dom_crawler.rst b/components/dom_crawler.rst index 55b7a55be45..3688e07c97c 100644 --- a/components/dom_crawler.rst +++ b/components/dom_crawler.rst @@ -231,7 +231,12 @@ and :phpclass:`DOMNode` objects: $html = $crawler->html(); The ``html`` method is new in Symfony 2.3. - In PHP < 5.3.6 it might return html entities which are not properly decoded. + + .. caution:: + + Due to an issue in PHP, the ``html()`` method returns wrongly decoded HTML + entities in PHP versions lower than 5.3.6 (for example, it returns ``•`` + instead of ``•``). Links ~~~~~