3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $replacements = array( '[PEDIDO]' => 123, '[NOME]' => 'Bruno Augusto', '[VALOR]' => 69.00, '[FRETE]' => 0, '[DESCONTO]' => 69.00, '[TOTAL]' => 'It\'s FREE!', ); //$msg = preg_replace( '/\[\w+\]/', ); var_dump( preg_quote( array_keys( $replacements ) ) );
Output for 5.2.0 - 7.1.0
Warning: preg_quote() expects parameter 1 to be string, array given in /in/taSu7 on line 13 NULL
Output for 4.3.0 - 5.1.6
Notice: Array to string conversion in /in/taSu7 on line 13 string(5) "Array"