Oct 22nd, 2009, 11:40 AM
RedirectView to external pdf
I'm trying to use RedirectView in my controller to redirect to a pre-generated PDF.
my handInternalRequest method returns this:
return new ModelAndView(new RedirectView(url));
It seems to be finding the PDF, but it isn't being opened by adobe. It is rendering it like a text file in the browser. I tried to set the responses ContextType to application/pdf, but that isn't working either.
Any ideas? What is the proper way to redirect to a PDF file using spring?
Oct 22nd, 2009, 12:10 PM
This actually works fine. I had a pathing problem with my pdf file.