Export Multiple Files from Single Source,
Posted: Sun Jun 01, 2008 2:55 am
I'm evaluating, very interested in whether I can perform multiple search and replace functions, on a single input file, generating a unique output after each filter is applied. Here's the scenario:
Starting with an html page, /root/index.html
find easy pattern to replace something like <META name="Description" content="
Replace with something like <META name="Description" content="New and improved
--> now, write this to a new index.html file in directory /root/newandimproved/index.html
--> then continue with a new pattern to replace the SAME <META name="Description" content=" from the original file /root/index.html
find easy pattern to replace something like <META name="Description" content="
Replace with something like <META name="Description" content="even better and improved
--> now, write this to a new index.html file in directory /root/evenbetter/index.html
... and so on, for about 200 different iterations of replacing the description. I'm basically attempting to take a single index.html file, and generate 200+ versions of it with new content, based on what I have placed in each search and replace filter.
Looking for any ideas / help while I evaluate.
Thanks!
Starting with an html page, /root/index.html
find easy pattern to replace something like <META name="Description" content="
Replace with something like <META name="Description" content="New and improved
--> now, write this to a new index.html file in directory /root/newandimproved/index.html
--> then continue with a new pattern to replace the SAME <META name="Description" content=" from the original file /root/index.html
find easy pattern to replace something like <META name="Description" content="
Replace with something like <META name="Description" content="even better and improved
--> now, write this to a new index.html file in directory /root/evenbetter/index.html
... and so on, for about 200 different iterations of replacing the description. I'm basically attempting to take a single index.html file, and generate 200+ versions of it with new content, based on what I have placed in each search and replace filter.
Looking for any ideas / help while I evaluate.
Thanks!