Another approach would be just to run diff on the
files and use CF to parse the resulting diff file and
apply formatting to the originals based on the diff.
--- Micha Schopman <[EMAIL PROTECTED]>
wrote:

> I came up with the algorithm because I have some
> experience with this
> subject, I haven't found any custom tags being able
> to compare
> documents, so I had to create one for a client last
> week. I don't have
> the tag by hand, unfortunately. What you have to do
> is split the strings
> create a matrix, and loop through the matrix to find
> the highest cost.
> Compare this cost to the minimal, diagonal and
> horizontal cost and you
> are able to find whether the string is added,
> modified or removed from
> the version. The process is very cpu intensive when
> running on
> ColdFusion, especially creating the matrix which is
> len(chars) *
> len(chars) in length.
>  
> I also made a PHP implementation which was way more
> faster than
> ColdFusion did.
>
>
> Micha Schopman
> Software Engineer
> Modern Media, Databankweg 12 M, 3821 AL  Amersfoort
> Tel 033-4535377, Fax 033-4535388
> KvK Amersfoort 39081679, Rabo 39.48.05.380
>
>
>
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings] [Donations and Support]

Reply via email to