If you have lots of words with brackets and you want to remove those brackets then use the below preg_replace expression:

$article = trim(preg_replace(‘/\s*\([^)]*\)/’, ”, $article));

This will remove such like brackets:

$artical = “WWF World Heavyweight Champion/WWF Champion (with his last reign being as Undisputed WWF/WWE Champion) and a six-time WCW World Heavyweight Champion. He was the first wrestler to win consecutive Royal Rumbles, in 1990 and 1991 respectively”;

 

Please login or Register to submit your answer
Not the answer you are looking for? Browse other questions tagged or ask your own question.