complex regex find/replace
-
Hi, I’ve been wrestling with a regex find/replace issue and I’m not having any success. I’ve tested my regex at: https://www.functions-online.com/preg_replace.html and https://www.phpliveregex.com/#tab-preg-replace and it works fine in both places.
Here is my shortcode:
[remote_content url="https://wolc.com/what-we-do/the-journey-for-adults/worship/christian-disciplines/prayer-for-the-week/" method="GET" timeout="10″ htmlentities="false" strip_tags="false" decode_atts="false" selector="#content" remove="#breadcrumbs" find="~<p><strong>Church\ Online\ Prayer\ Requests</strong></p>.*~sim" replace="</section>" cache="true" cache_ttl="3600″]
I get the section with the id “#content” just fine but the regex to get rid of the second half of the section is not working. I get the whole section back as if the regex was ignored.
Any thoughts of other places I could test to work this out? Thanks for this great plugin!
The page I need help with: [log in to see the link]
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘complex regex find/replace’ is closed to new replies.