3v4l.org

run code in 300+ PHP versions simultaneously
<?php $xml = '<rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:admin="http://webns.net/mvcb/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" version="2.0"> <channel> <title>Breaking News - Racer X Online</title> <link>http://racerxonline.com/</link> <description> Racer X Online is the world\'s top source for breaking motocross and supercross news. </description> <lastBuildDate>Thu, 09 Apr 2015 02:07:26 -0400</lastBuildDate> <ttl>10</ttl> <language>En</language> <atom:link href="http://racerxonline.com/feeds/rss/category/breaking-news" rel="self" type="application/rss+xml"/> <copyright>Copyright 2015 - Racer X Online</copyright> <image> <link>http://racerxonline.com/</link> <title>Breaking News - Racer X Online</title> <url>http://rx.iscdn.net/i/logos/racer-x-thumb.png</url> </image> <item> <title>Houston Animated Track Map</title> <link> http://racerxonline.com/2015/04/08/houston-animated-track-map?utm_medium=RSS&utm_source=Feed&utm_campaign=Breaking+News+-+Racer+X+Online </link> <guid> http://racerxonline.com/2015/04/08/houston-animated-track-map </guid> <pubDate>Wed, 08 Apr 2015 13:00:00 -0400</pubDate> <description> <![CDATA[ Take a lap with the green arrow. ]]> </description> <media:content url="//rx.iscdn.net/2015/04/96341_rd14_houston01thumb.jpg" type="image/jpeg" medium="image"/> </item> </channel> </rss>'; $xml = simplexml_load_string($xml); foreach( $rss->channel->item as $child) { echo $child . "\n"; }
Output for git.master, git.master_jit, rfc.property-hooks
Warning: simplexml_load_string(): Entity: line 21: parser error : EntityRef: expecting ';' in /in/btPH8 on line 35 Warning: simplexml_load_string(): racerxonline.com/2015/04/08/houston-animated-track-map?utm_medium=RSS&utm_source in /in/btPH8 on line 35 Warning: simplexml_load_string(): ^ in /in/btPH8 on line 35 Warning: simplexml_load_string(): Entity: line 21: parser error : EntityRef: expecting ';' in /in/btPH8 on line 35 Warning: simplexml_load_string(): 015/04/08/houston-animated-track-map?utm_medium=RSS&utm_source=Feed&utm_campaign in /in/btPH8 on line 35 Warning: simplexml_load_string(): ^ in /in/btPH8 on line 35 Warning: Undefined variable $rss in /in/btPH8 on line 36 Warning: Attempt to read property "channel" on null in /in/btPH8 on line 36 Warning: Attempt to read property "item" on null in /in/btPH8 on line 36 Warning: foreach() argument must be of type array|object, null given in /in/btPH8 on line 36

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:
43.96 ms | 403 KiB | 8 Q