How to use same string (character) with PHP str_replace to open and close tag?

php substr
php string replace
php trim
php str_replace multiple
php str_replace regex
remove specific characters from string php
str replace
php replace special characters