incuna/django-wkhtmltopdf — pull request #33 by mrshu (2013-03-09 11:50:35+00:00)
Title: fixed empty URLs

'I've spent 4 hours trying to figure out why the generated PDF does not consider CSS rules.

Well, I found out (by looking into the `/tmp` directory) that everything in brackets got replaced with `file://`. That meant no CSS would get applied.

Then I figured that it was because of the fact that my MEDIA_URL was empty and thus the regex that looks for the links tried to prepend everything inbrackets with `file://`.

This pull request tries to fix this behaviour and save the mankind some human hours.