Forum .LRN Q&A: Re: Using Xowiki from the Learning Design Player GRAIL

Posted by Gustaf Neumann on
Dave, is there any documentation, on which kind of HTML input util::html_diff is supposed to work? The simple example

util::html_diff -old "<a href='.'>x</a>" -new "<a href='.'>x</a>"

returns invalid HTML:

<a href='.'> x </span>

If you look at the code, it is clear why (see the final string map). The following trivial example leads to a tcl-error:

util::html_diff -old "ppp" -new "ppp xxx"

which is easy to fix. But nevertheless, I get certain doubts that this code is tested and in use by any application with HTML.


Posted by Gustaf Neumann on
Just a followup to my own posting: i fixed three bugs in util::html_diff (see commit log and commited to CVS HEAD. For some random examples, the output seems now quite ok. I'll add some optional support to xowiki to use it.

However, i noticed that tagging of acs-tcl/tcl/util-diff-procs.tcl is unusual/strange/wrong. Although this file is in CVS HEAD, it is tagged with openacs-5-4-compat; as a consequence, it does not show up in a checkout with tag oacs-5-4, but it will be contained in "install/update" from repository. Not sure, who has tagged it with which intentions. Maybe the goal was to include it in oacs-5-4?