On Mon, 16 Aug 2004 11:22:30 +0300, Skippy <[EMAIL PROTECTED]> wrote:
> I'm looking for PHP code that will produce diff's between two texts, and
> render them "inline". By that I mean not the standard *nix diff output,
> which compares and outputs lines, but a diff that compares inline text
> and outputs the bits before and after in place, marked with a custom
> <span> or something.
> 
> Example of *nix diff:
> 
> - this is the old line
> + this is the new line
> 
> Example of what I need:
> 
> this is the <span class="old">old</span> <span class="new">new</span> line
> 
> I've seen this done in the htmldiff package, which is a C program. Except
> I don't want to diff HTML code, but regular text. I actually need this
> for a wiki engine, so it can present diffs between page changes in a
> better way.
> 
> So:
> * Anybody seen such code? the PEAR diff only does line diffs.
> * Know of any GPL'd wiki engine which has my kind of diffs already
>   implemented (as PHP?)
> * Any pointers about how I should go about writing my own such diff?
> 

There's a python program called CVSSpam that does somehting like that.
It does line changes, but also highlights the changes within the line.

Sorry, I know of no in-line PHP diff engine.

-- 
DB_DataObject_FormBuilder - The database at your fingertips
http://pear.php.net/package/DB_DataObject_FormBuilder

paperCrane --Justin Patrin--

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to