Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Is it possible to replace a couple of single character in one regular expression?
I want to replace all of these characters: \ | # & ? / \ out of my text (title)
I tried this exspression:
/\|\#\&\?\/\\/g
and used nothing for the replacement pattern because I want the characters to be replaced by nothing (only deleted). It will not validate.
I tried this also with a test word as replacement, but I am not sure how the replacement syntax looks like?
please some help,
thanks
Comments
Comment #1
twistor CreditAttribution: twistor commentedThe simpletest way to do this would just be to add multiple instances of the find replace plugin.
The g modifier isn't supported in PHP.