file compare with highlight the difference

Discussion in 'ASP General' started by jyoti, May 10, 2004.

  1. jyoti

    jyoti Guest

    I am new in asp. I have two html files. I like to write
    code to compare those two files. I like to show the
    difference as highlighted area.

    Example: File 1 contains:
    <html><body> Compare Test</body></html>

    File 2 contains:
    <html><body> Compare Test modyfied</body></html>
    I like to make either the word "modyfied" highlighted or
    the whole line highlighted on File2.

    I appreciate your help. Code sample will be helpful.

    Thanks
    Jyoti
    jyoti, May 10, 2004
    #1
    1. Advertising

  2. jyoti

    J. Baute Guest

    "jyoti" <> wrote in message news:<afd701c436c5$9c325ce0$>...
    > I am new in asp. I have two html files. I like to write
    > code to compare those two files. I like to show the
    > difference as highlighted area.
    >
    > Example: File 1 contains:
    > <html><body> Compare Test</body></html>
    >
    > File 2 contains:
    > <html><body> Compare Test modyfied</body></html>
    > I like to make either the word "modyfied" highlighted or
    > the whole line highlighted on File2.
    >
    > I appreciate your help. Code sample will be helpful.
    >
    > Thanks
    > Jyoti


    Writing diff programs is something that's done before quite a few
    times. Perhaps you should try and find some code of another
    implementation instead of writing your own from scratch, which will
    definatly save you a lot of time.

    Perhaps you can even use an external diff tool like WinDiff, which you
    can run from the commandine and export the results as a textfile. That
    way you only have to parse the output file itself, and not bother
    doing the actual comparing yourself.
    J. Baute, May 11, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. zw
    Replies:
    0
    Views:
    351
  2. jyoti
    Replies:
    0
    Views:
    115
    jyoti
    Jun 4, 2004
  3. Mmcolli00 Mom
    Replies:
    11
    Views:
    335
    Mmcolli00 Mom
    Dec 10, 2008
  4. PerlFAQ Server
    Replies:
    0
    Views:
    177
    PerlFAQ Server
    Feb 6, 2011
  5. PerlFAQ Server
    Replies:
    0
    Views:
    154
    PerlFAQ Server
    Apr 4, 2011
Loading...

Share This Page