Well, I have no idea of this and how to do this but its making me go crazy. so here is the thing..
suppose i have this piece of code in say 20 files.
while(//some_condition):
.....
// do something here
.....
endwhile;
Now i need to wrap this loop within a conditional tag say something like this.
if(// condition_for_if ):
while(//some_condition):
.....
//do something here
.....
endwhile;
endif;
The problem is, its a super tedious job if you have this in large number of files, sometimes with multiple instances within one single file.
How can i automate the process? can i write a script in php to do that? At first the idea of installer scripts like the one wordpress has came to my mind but i clearly understood that it cannot be done that way.
What to do?