Forum How do I...?

Command-line call to create PDF from SVG that includes a referenced image that has a space in the filename

redherring917
Command-line calls to Prince to create a PDF from an SVG that includes a referenced image that has a space in the filename results in that image being excluded (missing) from the PDF. The Prince log file notes:

http:// [ my_valid_url ] /files/img_upload/movie clapper.jpg: warning: The requested URL returned error: 400

The image file named "movie clapper.jpg" does in fact exist at the public url referenced and can be browsed to as such. If I replace the space in the image filename with an underscore, it then is included in the PDF created by Prince with no associated errors being generated.

I grew up understanding that "spaces were evil" in filenames, but they're pretty prevalent nowadays. I hate to think that I need to rename any such file on the fly pre my call to Prince.

Please advise.

Thanks!
mikeday
400 is an odd error, it indicates there is something else in the request that the server did not like. Can you run Prince with the --debug option and check in the output log exactly what URL Prince is sending to the server? The main question is whether the space is escaped as %20 or not.
redherring917
Thanks Mike. Spaces have now been accounted for and replaced up-stream of Prince and all seems well.