BerndGabriel/HtmlViewer — pull request #15 by JPeterMugaas (2012-01-06 17:47:30+00:00)
Title: Relative URL's in Style sheets and spaces in pathes.

Fix for relative URL to absolute URL for background image.
If a path contains a space, it winds up being truncated. I traced this down.
The relative URL "url('../gfx/comp010.jpg')" was converted to:

'url(file://C|/Users/X. Example/Documents/WebsiteJPeterMugaas/gfx/comp010.jpg)'

and when processed again by ReadUrl, it was becoming:

file://C|/Users/X.'

This can occur very easily because a space is a legal filename character in Windows and Unix-like operating systems. A simple fix was to change the conversion result to:

'url("file://C|/Users/X. Example/Documents/WebsiteJPeterMugaas/gfx/comp010.jpg")'

I have verified that this does work. There may be a better fix though. You should also check THTMLViewer 12 for similar problems.