#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2000
    Posts
    58
    Rep Power
    15
    Someone has "Frontpage'ed" our static site with bloody webbot comments that I now want out!

    I want to look for this and replace it with nothing.
    How do I replace the 59711 with a regular expression?
    <!--webbot bot="Include" endspan i-checksum="59711" -->

    And how do I write a regular expression for replacing this with nothing.
    <!--webbot bot="Include" u-include="../../nav/template/confall.htm" tag="BODY" startspan -->
    '../../nav/template/confall.htm' should obviously be replaced with a regular expression.

    It would be nice if I could use the regular expression Extended Replace directly in HomeSite.
  2. #2
  3. Senior Member
    Devshed Intermediate (1500 - 1999 posts)

    Join Date
    Jun 2000
    Location
    Enschede, The Netherlands
    Posts
    1,527
    Rep Power
    16
    Hasn't much to do with PHP in my point of view...

    But yeah.. I think it's the easiest way to replace all this stuff by using some editor you use (replace command). I have no experience with HomeSite, but I assume it has the capabilities to do it.
    (I use UltraEdit myself and there I can replace some string#1 with another string#2 in multiple files by selecting the directory I want.)

    Mirax
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2000
    Posts
    58
    Rep Power
    15
    I know HomeSite very well, and how to do Extended Replaces, but I don't know Regular Expressions.



    ------------------

    peterbe.com
  6. #4
  7. Senior Member
    Devshed Intermediate (1500 - 1999 posts)

    Join Date
    Jun 2000
    Location
    Enschede, The Netherlands
    Posts
    1,527
    Rep Power
    16
    Hmm.. sorry, but I'm not familiar with HomeSite (not at all) so I have no idea which Regular Expressions you mean..

    Isn't there something like this in HomeSite?
    This shouldn't be that difficult should it?
  8. #5
  9. Senior Member
    Devshed Intermediate (1500 - 1999 posts)

    Join Date
    Jun 2000
    Location
    Enschede, The Netherlands
    Posts
    1,527
    Rep Power
    16
    Well, I saw UltraEdit had some Regular Expressions as well
    So I took a look a the help files and there it's explained very clearly. I assume HomeSite also has such a help-function...

    Mirax
  10. #6
  11. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2000
    Posts
    58
    Rep Power
    15
    Homesite has Regular Expression support and I also found out how to use it and so forth.

    I just didn't know how to write the REGULAR EXPRESSION!.

    Now I do. I looked for
    <!--webbot bot="Include" endspan i-checksum="[0-9]+" -->

    ------------------

    peterbe.com
  12. #7
  13. .Net Developer
    Devshed Novice (500 - 999 posts)

    Join Date
    Feb 2000
    Location
    London
    Posts
    987
    Rep Power
    15

    <<
    Homesite has Regular Expression support and I also found out how to use it and so forth.
    I just didn't know how to write the REGULAR EXPRESSION!.
    >>


    Are you trying to do regular expressions in Php??

    if yes,then read following article for learning regular expressions..
    http://www.phpbuilder.com/columns/dario19990616.php3


    ------------------
    SR -
    webshiju.com

    "The fear of the LORD is the beginning of knowledge..."
  14. #8
  15. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2000
    Posts
    58
    Rep Power
    15
    Thank you Shiju Rajan. That helped.

Similar Threads

  1. DBI warnings -- plz help
    By pranesh in forum Perl Programming
    Replies: 4
    Last Post: December 1st, 2003, 07:52 PM
  2. CGI.pm, regular expression proublem
    By xen in forum Perl Programming
    Replies: 6
    Last Post: September 30th, 2003, 09:14 PM
  3. quick regular expression help
    By Jay Edgar in forum PHP Development
    Replies: 2
    Last Post: June 26th, 2003, 02:02 PM
  4. regular expression help --href extraction
    By pchad in forum PHP Development
    Replies: 7
    Last Post: September 1st, 2002, 08:47 PM
  5. $variable = regular expression match..?
    By dave_mwi in forum Perl Programming
    Replies: 2
    Last Post: April 12th, 2002, 05:43 PM

IMN logo majestic logo threadwatch logo seochat tools logo