If the "Absolute path (relative to document root)" option is selected on the filter settings form, only links to nodes are affected, but not files. Thus, files are always rendered as absolute URLs.

Since file_create_url() always returns absolute URLs, the only way to do this is to remove the base_url from the returned path in _pathfilter_process_files(). This is accomplished in the provided patch.

Files: 
CommentFileSizeAuthor
pathfilter.module.patch723 bytesjoelstein

Comments

Status:Active» Fixed

Good catch, and patch. This has now been applied to D6 and 5 branches in CVS.

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.