<?php $text = "Voilà. C'est vrai.";echo preg_replace("/(<br>|[\s’'])/u", "$1|||", $text);
Standard input is empty
Voilà. |||C'|||est |||vrai.
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!