Jump to content

Use PHP to search through entire server for text in files


woocha

Recommended Posts

Hi guys...I am not sure if this is possible, but I need a way to search through all of the files on my server.  some piece of crap bug was spread to one of my severs and a bunch of the php and html files had an iframe attached to the bottom of them.  I have downloaded all al;l infected files and altered all 150, but I seem to be missing one.  So I want to do a sever wide search using php to find this one line bit of code and delete it.  Does anyone know how to do this with php?

Ya, I could, but I was hoping for a much quick solution.  There are literally 1000's of files on this ine server.

to change every text file on a server means you need to open, check and if required change and save, EVERY file... unless you know some better magic. And hey at least you don't have to do it by hand.

 

And yes jonsjavas' variation would be faster, but you did specify with php...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.