3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = '<input type="checkbox" name="jesus">'; echo preg_replace('/<input(\s+)type="checkbox"(\swW+)/', 'hi', $str);

preferences:
43.05 ms | 402 KiB | 5 Q