3v4l.org

run code in 300+ PHP versions simultaneously
<?php $data = "<p>This is some <b>data</b> It has some <i>new lines</i> in it &amp; it has some <u>HTML</u> in it</p> <div>Look, there's some more new lines</div>"; var_dump($data); echo "\n\n"; $stripped = html_entity_decode(strip_tags($data)); var_dump($stripped); echo "\n\n"; $json = json_encode($stripped); var_dump($json); echo "\n\n"; $decoded = json_decode($json); var_dump($decoded);
Output for git.master, git.master_jit, rfc.property-hooks
string(148) "<p>This is some <b>data</b> It has some <i>new lines</i> in it &amp; it has some <u>HTML</u> in it</p> <div>Look, there's some more new lines</div>" string(105) "This is some data It has some new lines in it & it has some HTML in it Look, there's some more new lines" string(110) ""This is some data\nIt has some new lines in it & it has some HTML in it\n\nLook, there's some more new lines"" string(105) "This is some data It has some new lines in it & it has some HTML in it Look, there's some more new lines"

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
30.8 ms | 402 KiB | 8 Q