run code in 200+ php & hhvm versions
Bugs & Features
<?php $str = '<!--BODY-->Thank you for enrolling for Invoice Gateway with Harry Cooper Supply Company<br /> <br /> To activate your Invoice Gateway account, please click the below link.<br /> <br /> If you cannot click this link, you should copy and paste this entire link into your browser or AOL address box and press enter.<br /> <br /> https://secure.billtrust.local/harrycooper/ig/signup/activate?t=12345BYCKCBJTVHPKU<!--ENDBODY-->'; $regex = "~t=(.*?)<!--ENDBODY-->~"; $output = preg_match_all($regex, $str, $matches); print_r(implode($matches[1]));
based on M2l9G
Output for 4.3.0 - 7.2.6