Need help from a programmer.

This is a discussion on Need help from a programmer. within the C++ Programming forums, part of the General Programming Boards category; I got a website for me and some of my friends but recently some hacker attacked it. I was hoping ...

  1. #1
    Registered User
    Join Date
    Apr 2011
    Posts
    1

    Need help from a programmer.

    I got a website for me and some of my friends but recently some hacker attacked it.
    I was hoping some one could write me a small command line program that will look trough all files in a folder if they contain a certain string and if they contain it remove that string.

    I am a beginner myself in programming and I got no idea how to do this.

  2. #2
    Registered User
    Join Date
    Jul 2007
    Posts
    131
    Code:
    $ for f in $(find .); do
    >    mv $f $f.tmp
    >    sed -e 's/<CERTAIN STRING>//g/' < $f.tmp > $f
    >    rm $f.tmp
    >done

  3. #3
    C++ Witch laserlight's Avatar
    Join Date
    Oct 2003
    Location
    Singapore
    Posts
    21,893
    Oh, please. *thread closed*
    C + C++ Compiler: MinGW port of GCC
    Version Control System: Bazaar

    Look up a C++ Reference and learn How To Ask Questions The Smart Way

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. C++ Programmer for PDF add-in
    By tariqjameel in forum C++ Programming
    Replies: 2
    Last Post: 03-15-2011, 07:49 AM
  2. New programmer - please help!
    By Brewer in forum C Programming
    Replies: 8
    Last Post: 10-06-2006, 03:53 PM
  3. New C Programmer -- Need help here!
    By xRandyx in forum C Programming
    Replies: 8
    Last Post: 09-05-2005, 04:44 PM
  4. The *&%$#!% programmer !
    By caroundw5h in forum A Brief History of Cprogramming.com
    Replies: 25
    Last Post: 06-01-2004, 07:21 PM
  5. Programmer Sex
    By Leeman_s in forum A Brief History of Cprogramming.com
    Replies: 1
    Last Post: 01-20-2003, 06:52 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21