I'm pretty sure that your problem comes from trying to create a
document from within a Prawnto view. My understanding is that Prawnto
creates a document and pushes it into your view, so you only have to
write your actual document code. But I would definitely recommend
using the documentation that Pascal pointed out; it's the recommended
way to use Prawn from Rails.
Brad
The instructions were written as if you're using git to manage your
project. If you're not, you'll just need to "git clone" Prawn into a
directory under your project, or use a gem version of Prawn.
> Not sure if that document is up to date. Also, I noticed that the URL
> that I was creating with routes, was ending up blank, but, I found
> within the main folder generated certificate.pdf that renders what I
> asked it to do... Very weird... How come the url I am loading is
> blank, but something is saved separately at the root?
As I mentioned earlier, Prawnto generates a Prawn::Document for you
and expects you to use it to render your data. But you are throwing it
away and creating a new Prawn::Document in your code, and saving it
off to the filesystem. So that document looks correct but the document
Prawnto gave you didn't have anything rendered to it.
-be