3v4l.org

run code in 300+ PHP versions simultaneously
<?php $text = "#test Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus #tristique non elit eu iaculis. Vivamus eget ultricies nisi. Vivamus hendrerit at mauris condimentum scelerisque. <a href='http://google.co.uk/#donec'>nibh</a> mauris, pulvinar et #commodo a, porta et tellus. Duis eget ante gravida, convallis augue id, blandit lectus. Mauris euismod commodo mi ut fringilla. Sed felis magna, rhoncus vitae mattis varius, sagittis a eros. Donec eget porta ipsum. <a href='#Mauris'>sed mauris ante</a>. Suspendisse potenti. Donec a #pretium #augue, eget hendrerit orci. Integer cursus scelerisque consequat."; $text = preg_replace('/(?:^|\s)#(\w+)/', ' <a href="tag/$1">$1</a>', $text); echo $text; ?>
Output for git.master_jit, git.master, rfc.property-hooks
<a href="tag/test">test</a> Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus <a href="tag/tristique">tristique</a> non elit eu iaculis. Vivamus eget ultricies nisi. Vivamus hendrerit at mauris condimentum scelerisque. <a href='http://google.co.uk/#donec'>nibh</a> mauris, pulvinar et <a href="tag/commodo">commodo</a> a, porta et tellus. Duis eget ante gravida, convallis augue id, blandit lectus. Mauris euismod commodo mi ut fringilla. Sed felis magna, rhoncus vitae mattis varius, sagittis a eros. Donec eget porta ipsum. <a href='#Mauris'>sed mauris ante</a>. Suspendisse potenti. Donec a <a href="tag/pretium">pretium</a> <a href="tag/augue">augue</a>, eget hendrerit orci. Integer cursus scelerisque consequat.

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:
25.46 ms | 407 KiB | 5 Q