3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = ' <li>Type: {{ad.type}}</li> <li>Logo: <img src="{{ad.display_url}}" alt="ad logo"></li> <li>Body: {{ad.body}}</li> <li>Headline: {{ad.headline}}</li> <li>Display Url: </li> <li>Expected Revenue: {{ad.expected_revenue}}</li> <li>Pricey: {{ad.price}}</li> <li>Client name and id: {{ad.client_name}} ({{ad.client_id}})</li> <li>Ad name and id: <a class="st_2" href="{{ad.url}}">{{ad.name}}({{ad.id}})</a></li> </ul> {% endif %} <!-- DEFAULT NOT USED EVEN AND ODD SUBTEMPLATES SET --> <!-- DEFAULT --> <a href="{{ad.url}}">{{ad.name}}</a> <ul> <li>Ad: <a href="{{ad.url}}">{{ad.name}}({{ad.id}})</a></li> <li>Client: {{ad.client_name}} ({{ad.client_id}})</li> <li>Price: {{ad.price}}</li> <li>Expected Revenue: {{ad.expected_revenue}}</li> <li>Display Url: {{ad.display_url}}</li> <li>Headline: {{ad.headline}}</li> <li>Body: {{ad.body}}</li> <li>Logo: <img src="{{ad.logo.url}}"/></li> <li>Type: {{ad.type}}</li> {% if ad.conditions|length %} <li>Conditions: </li> <ul> {% for condition in ad.conditions %} <li>{{condition.conditiontype.name}} {{condition.operator}} {{condition.value}} </li> {% endfor %} </ul> {% endif %} </ul--> <!-- DEFAULT --> {% endif %} {% endfor %}'; print_r(explode($string,'<!-- DEFAULT -->'));

preferences:
39.57 ms | 402 KiB | 5 Q