I have the following string that i want to replace parts of:
Blah blah Mr. [-user_first_name-] [-user_last_name-]
This will replace verything [- -]:
preg_replace('/[^\[-[a-z\d_\/A-Z. ]+-\]]/i', '', $body);
My goal is to replace everything that isn't in [- -]
Do you know how I can make this worth?