Jump to content


 


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo

mass removal of text


  • Please log in to reply
4 replies to this topic

#1 gorydragon

gorydragon

  • Members
  • 55 posts
  • OFFLINE
  •  
  • Local time:09:20 PM

Posted 11 May 2010 - 05:13 PM

how can i do a removal of the same piece of code from a lot of files?
i was using the free web hosting service on webs.com as a temporary holder for the files of a website im designing. now that im done, i realize webs inserted this code into every one of the pages.
<noscript></noscript><!-- --><script type="text/javascript" src="http://www.freewebs.com/p.js"></script><script LANGUAGE="JavaScript">
can i run a script or command or something for it to delete that bit from all files?

BC AdBot (Login to Remove)

 


#2 groovicus

groovicus

  • Security Colleague
  • 9,963 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Centerville, SD
  • Local time:08:20 PM

Posted 11 May 2010 - 05:32 PM

You could, but as long as you store it there it will keep adding it back.

At any rate, open the file in any text editor and use the find/replace function to replace whatever text you want removed. Unless you have hundreds of pages, it will be quicker to do it that way then it would be to write up the code to do it.

#3 Romeo29

Romeo29

    Learning To Bleep


  • BC Advisor
  • 3,194 posts
  • OFFLINE
  •  
  • Gender:Not Telling
  • Location:127.0.0.1
  • Local time:09:20 PM

Posted 12 May 2010 - 06:50 AM

grepWin can help you out. Search for this text and all files and replace with an empty string.
http://code.google.com/p/grepwin/

#4 gorydragon

gorydragon
  • Topic Starter

  • Members
  • 55 posts
  • OFFLINE
  •  
  • Local time:09:20 PM

Posted 12 May 2010 - 02:01 PM

I finished and am moving it to the domain, It'll be on webs no longer.

#5 gorydragon

gorydragon
  • Topic Starter

  • Members
  • 55 posts
  • OFFLINE
  •  
  • Local time:09:20 PM

Posted 12 May 2010 - 06:22 PM

Thanks romeo29, grepwin did the job perfectly.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users