Home » Forum
NoNumber!

Joomla! extensions & websites
development / support / consultancy

I try to respond within 24 hours (excluding weekends). If I haven't responded by then, feel free to post a reminder or bug me via email.
Welcome, Guest
Please Login or Register.    Lost Password?

Search/Replace several lines of code
(1 viewing) (1) Guest
Go to bottomPage: 1
TOPIC: Search/Replace several lines of code
#9723
Search/Replace several lines of code 2 Months, 1 Week ago  
Hi,

ReReplacer has worked really well for simple find/replace (thanks!!), and now I need a little help for something a bit more complicated.

I need to remove several lines of code that appear between tags, where the content in between the tags may vary.

How do I search/remove the following example (please note that there may be several <form></form> tags on each page, yet I only want to remove the following one)


<form class="cb_form" name="adminForm" id="adminForm" method="get"
---code between open and close tags vary, and can be in excess of 50 lines of code---
</div> </form>


I have attempted to do this with regex website info, but I have been unsuccessful

Thanks for your great software

Cheers!
Rick Whalley
Posts: 1
User OfflineClick here to see the profile of this user
The administrator has disabled public write access.
 
#9724
Re: Search/Replace several lines of code 2 Months, 1 Week ago  
That's where regular expressions come in. Try to search for:
<form class="cb_form".*?</form>
Peter van Westen
Admin
Posts: 4533
User OfflineClick here to see the profile of this user
The administrator has disabled public write access.
Need to contact me directly? Go to my contact page.
If you use any NoNumber! extensions, please post a rating and a review at the Joomla! Extensions Directory.
Are you happy with the support? Please consider buying a License Code to help me to continue development and support.
 
Go to topPage: 1
Joomla Open Source Training