fork download
  1. <?php
  2. $input = <<< EOF
  3. This is Before HELLO
  4.  
  5. @@MESsage@@
  6.  
  7. @@MESSAGE@@
  8.  
  9. Hello @@MESSAGE@@ssd
  10.  
  11. This is After
  12. EOF;
  13. echo preg_replace('/\B@@MESSAGE@@\B/', 'replaced', $input);
  14. ?>
Success #stdin #stdout 0.01s 20520KB
stdin
Standard input is empty
stdout
This is Before HELLO

@@MESsage@@

replaced

Hello @@MESSAGE@@ssd

This is After