Braces in image filename
I'm getting the following error:
Mon Jun 1 17:19:44 2009: /userImages/{B3BE6BE8-51B3-4367-9967-C08817AE4AB1}/web/11.jpg: warning: can't open input file: No such file or directory
with an image even though the image is displayed in all current browsers.
Prince works correctly with the same file but the braces removed from the path.
Which platform are you running on, is the input document a local file, and are you using the --baseurl command-line argument?
Hi Mikeday,
It is running on Windows Server 2k3, it's a remote web page, not using the --baseurl command-line argument.
Also using the activeX/COM addon.
The braces might be breaking the URL resolution. Could you try escaping them with %7B for { and %7D for } ?
Hi Mikeday,
I get the same error with the escaped version.
That's odd, it fixed the problem here for me.
Are there any other "special" characters in the URL? And just to confirm, did the modified URL "/userImages/%7BB3BE6BE8-51B3-4367-9967-C08817AE4AB1%7D/web/11.jpg" produce exactly the same error?
Mike,
I was running HtmlEncode on the string which I thought encoded the braces with %7B/%7D, but it doesn't actually do anything with them.
UrlEncode on the other hand encodes the braces with the %7B/%7D (along with the hyphens to %2D), and corrects the problem.
Apologies for wasting your time.
No problem! We've made a tweak to the next release of Prince so that it will also try escaping characters if the URL fails to resolve correctly.