We have file names containing the '#' character. When node view is set to 'url to file' display, '#' is properly encoded as '#23', but when node view is set to 'generic file display' it is not properly encoded, resulting in page not found error.

Fixed by adding

$url = file_create_url($path);
/* '#' fix */ $url = str_replace('#', '%23', $url);
$icon = theme('filefield_icon', $file);

to line 125 in filefield_formatter.inc

Comments

quicksketch’s picture

Unfortunately this is a Drupal core bug, see #238299: file_create_url should return valid URLs. I suggest installing Transliteration to avoid the problem.

quicksketch’s picture

Sorry that issue was marked duplicate, here's the issue that now addresses it: #284899: Drupal url problem with clean urls.

quicksketch’s picture

Status: Active » Closed (duplicate)
heacu’s picture

subscribe