3v4l.org

run code in 300+ PHP versions simultaneously
<?php $list = []; $list[] = "TALB20170826D-\$A$$-RA11.pdf"; $list[] = "TAP$20170826D-\$A$$-RA11.pdf"; $list[] = "TASD20170826D-\$A$$-RA11.pdf"; $list[] = "TAUA20170826D-\$A$$-RA11.pdf"; $list[] = "TAUB20170826D-\$A$$-RA11.pdf"; $list[] = "TAUC20170826D-\$A$$-RA11.pdf"; $list[] = "TAUD20170826D-\$A$$-RA11.pdf"; $list[] = "TBTP20170826D-\$A$$-RA11.pdf"; $list[] = "TCBY20170826D-\$A$$-RA11.pdf"; $abbr = [ "TALB", "TAP", ]; $replacements = [ "ALBANY", "Asia Pacific", ]; foreach ($list as &$el) { $el = str_replace($abbr, $replacements, $el); } var_dump($list);
Output for git.master, git.master_jit, rfc.property-hooks
array(9) { [0]=> string(29) "ALBANY20170826D-$A$$-RA11.pdf" [1]=> string(36) "Asia Pacific$20170826D-$A$$-RA11.pdf" [2]=> string(27) "TASD20170826D-$A$$-RA11.pdf" [3]=> string(27) "TAUA20170826D-$A$$-RA11.pdf" [4]=> string(27) "TAUB20170826D-$A$$-RA11.pdf" [5]=> string(27) "TAUC20170826D-$A$$-RA11.pdf" [6]=> string(27) "TAUD20170826D-$A$$-RA11.pdf" [7]=> string(27) "TBTP20170826D-$A$$-RA11.pdf" [8]=> &string(27) "TCBY20170826D-$A$$-RA11.pdf" }

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:
17.46 ms | 402 KiB | 8 Q