regex - Find Two Words on url string -
i'm trying find 2 words on urls, looks underscore don't allow word found
/\bmedium\b|\wmed_crop\w/i
why use \w around "med_crop". \w matches [a-za-z0-9_], not slashes. also, need use global modifier g if want match more 1 @ time.
this seems work in example
/\bmedium\b|\bmed_crop\b/ig
Comments
Post a Comment