By mikepetersonwi on
Running Drupal 5.3 with Clean URLs.
1. I upload (attach) a file that includes an ampersand ("&") in the filename.
2. The file is saved to disk with the ampersand preserved correctly.
3. The table view that displays a link to the file replaces the ampersand with "&" (without quotes).
4. Because the syntax of the link in incorrect, I get a "Page not Found"
Question: How do I preserve the correct filename and path in the table view?
Any suggestions are appreciated.
Mikep
Comments
...
The ampersand is actually supposed to be be escaped. But then you didn't paste the HTML so I can't say for sure. I suggest you file an issue.
HTML of Link
Mooffie,
I'm not sure what HTML you're asking about but here a few pieces:
1. HTML of the link in the Table View is
<a href="http://www.mysitename.com/files/one &amp; two.pdf">Open</a>2. HTML of the attachment when viewing the node is:
Do either one of these help?
Mikep
...
That's a bug. The ampersand is escaped *twice*. I had a look at 'views_upload.inc' and, indeed, it has:
The check_url() is redundant --most probably.
You should open an issue against Views. But search first, perhaps it's a known bug.
...
I opened an issue:
http://drupal.org/node/212853
Thanks mooffie...
I was intending to get back to this.
Thanks again,
Mikep