3v4l.org

run code in 300+ PHP versions simultaneously
<?php $oPricingInfoNode = new DOMDocument(); $oPricingInfoNode->loadXML(' <air:AirPricingInfo xmlns:air="http://www.travelport.com/schema/air_v22_0" xmlns:com="http://www.travelport.com/schema/common_v19_0" Key="4T" TotalPrice="EUR50.99" BasePrice="EUR2.00" ApproximateTotalPrice="EUR50.99" ApproximateBasePrice="EUR2.0 0" Taxes="EUR48.99" LatestTicketingTime="2013-10-27T23:59:00.000+00:00" PricingMethod="Auto" ProviderCode="1P"> <air:AirPricingModifiers FaresIndicator="PublicAndPrivateFares" /> <air:FareInfo Key="6T" FareBasis="PBE604K" PassengerTypeCode="ADT" Origin="BRU" Destination="MAD" EffectiveDate="2013-10-26T20:36: 45.370+02:00" Amount="NUC1.31"> <air:FareRuleKey FareInfoRef="6T" ProviderCode="1P">3Dxtd/jsY9Lo40qgTiQTot3Ga9aZj+SyHmN4mO25YCrug9CQWuP+X2+oD5t4/MZlfXbbvYG4TG43 VNwAhz2PnWmWLv0xpQB8</air:FareRuleKey> </air:FareInfo> <air:FareInfo Key="7T" FareBasis="PBE604K" PassengerTypeCode="ADT" Origin="MAD" Destination="BRU" EffectiveDate="2013-10-26T20:36: 45.370+02:00" Amount="NUC1.31"> <air:FareRuleKey FareInfoRef="7T" ProviderCode="1P">3Dxtd/jsY9Lo40qgTiQTot3Ga9aZj+Syda+Y0VQMYBHug9CQWuP+X2+oD5t4/MZlfXbbvYG4TG43 VNwAhz2PnWmWLv0xpQB8</air:FareRuleKey> </air:FareInfo> <air:BookingInfo BookingCode="P" FareInfoRef="6T" SegmentRef="2T" Origin="BRU" Destination="MAD" /> <air:BookingInfo BookingCode="P" FareInfoRef="7T" SegmentRef="3T" Origin="MAD" Destination="BRU" /> </air:AirPricingInfo>'); # $oPricingInfoNode->insertBefore( echo $oPricingInfoNode->saveXML();
Output for 5.0.0 - 5.0.5, 5.1.0 - 5.1.6, 5.2.0 - 5.2.17, 5.3.0 - 5.3.29, 5.4.0 - 5.4.45, 5.5.0 - 5.5.38, 5.6.0 - 5.6.38, 7.0.0 - 7.0.33, 7.1.0 - 7.1.25, 7.2.0 - 7.2.33, 7.3.0 - 7.3.33, 7.4.0 - 7.4.33, 8.0.0 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.6
<?xml version="1.0"?> <air:AirPricingInfo xmlns:air="http://www.travelport.com/schema/air_v22_0" xmlns:com="http://www.travelport.com/schema/common_v19_0" Key="4T" TotalPrice="EUR50.99" BasePrice="EUR2.00" ApproximateTotalPrice="EUR50.99" ApproximateBasePrice="EUR2.0 0" Taxes="EUR48.99" LatestTicketingTime="2013-10-27T23:59:00.000+00:00" PricingMethod="Auto" ProviderCode="1P"> <air:AirPricingModifiers FaresIndicator="PublicAndPrivateFares"/> <air:FareInfo Key="6T" FareBasis="PBE604K" PassengerTypeCode="ADT" Origin="BRU" Destination="MAD" EffectiveDate="2013-10-26T20:36: 45.370+02:00" Amount="NUC1.31"> <air:FareRuleKey FareInfoRef="6T" ProviderCode="1P">3Dxtd/jsY9Lo40qgTiQTot3Ga9aZj+SyHmN4mO25YCrug9CQWuP+X2+oD5t4/MZlfXbbvYG4TG43 VNwAhz2PnWmWLv0xpQB8</air:FareRuleKey> </air:FareInfo> <air:FareInfo Key="7T" FareBasis="PBE604K" PassengerTypeCode="ADT" Origin="MAD" Destination="BRU" EffectiveDate="2013-10-26T20:36: 45.370+02:00" Amount="NUC1.31"> <air:FareRuleKey FareInfoRef="7T" ProviderCode="1P">3Dxtd/jsY9Lo40qgTiQTot3Ga9aZj+Syda+Y0VQMYBHug9CQWuP+X2+oD5t4/MZlfXbbvYG4TG43 VNwAhz2PnWmWLv0xpQB8</air:FareRuleKey> </air:FareInfo> <air:BookingInfo BookingCode="P" FareInfoRef="6T" SegmentRef="2T" Origin="BRU" Destination="MAD"/> <air:BookingInfo BookingCode="P" FareInfoRef="7T" SegmentRef="3T" Origin="MAD" Destination="BRU"/> </air:AirPricingInfo>
Output for 4.3.2 - 4.3.11, 4.4.0 - 4.4.9
Fatal error: Cannot instantiate non-existent class: domdocument in /in/9MZgo on line 3
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Cannot instantiate non-existent class: domdocument in /in/9MZgo on line 3

preferences:
266.8 ms | 401 KiB | 424 Q