# Download a content as a pdf format

**URL:** <https://www.ruby-forum.com/t/download-a-content-as-a-pdf-format/158272>\
**Category:** Rails\
**Created:** [January 21, 2009, 2:49pm UTC](https://www.ruby-forum.com/t/download-a-content-as-a-pdf-format/158272 "2009-01-21T14:49:55Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![cool](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/c6cbf5/32.png) [@cool](https://www.ruby-forum.com/u/cool)\
**Post date:** [January 21, 2009, 2:49pm UTC](https://www.ruby-forum.com/t/download-a-content-as-a-pdf-format/158272/1 "2009-01-21T14:49:55Z")

</div>

Guys,

i am displaying this content in the view

```
WASC Visit
    25 Feb
               We also will be making final preparations for our

```

WASC Accreditation Team’s visit  
March 10, 11 and 12. They will be using the Old  
Computer Room as their meeting  
place during the visit but they also will be  
visiting classrooms, recesses, assemblies…  
Open House and Lenten Food Drive

```
               We also will be making final preparations for our

```

WASC Accreditation Team’s visit  
March 10, 11 and 12. They will be using the Old  
Computer Room as their meeting  
place during the visit but they also will be  
visiting classrooms, recesses …

```
   WASC Visit
   22 Feb
              We also will be making final preparations for our

```

WASC Accreditation Team’s visit  
March 10, 11 and 12. They will be using the Old  
Computer Room as their meeting  
place during the visit but they also will be  
visiting classrooms, recesses, assemblies…

…

Beside that i have a link called “Download as a PDF”

when i click on that link it should be downloaded as a pdf and in  
that pdf the content should be the above that i am displaying…

Can u help me guys.  
I am struck with this functionality

---

<div class="post-metadata">

**Author:** ![cool](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/c6cbf5/32.png) [@cool](https://www.ruby-forum.com/u/cool)\
**Post date:** [January 21, 2009, 3:45pm UTC](https://www.ruby-forum.com/t/download-a-content-as-a-pdf-format/158272/2 "2009-01-21T15:45:31Z")

</div>

cool wrote:

> Beside that i have a link called “Download as a PDF”  
> There are several solutions for generating PDF documents from Rails  
> applications.

Here’s one:  
[http://prawn.majesticseacreature.com/](http://prawn.majesticseacreature.com/)

---

<div class="post-metadata">

**Author:** ![cool](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/c6cbf5/32.png) [@cool](https://www.ruby-forum.com/u/cool)\
**Post date:** [January 21, 2009, 4:37pm UTC](https://www.ruby-forum.com/t/download-a-content-as-a-pdf-format/158272/3 "2009-01-21T16:37:44Z")

</div>

You can use flying saucer (a xhtml renderer java based) too, using XHTML  
as pdf template.

Recently is available as a rails plugin:

> **[GitHub - dagi3d/acts\_as\_flying\_saucer: acts\_as\_flying\_saucer is a Ruby On Rails...](https://github.com/dagi3d/acts_as_flying_saucer/tree/master)**
>
> master

A simple app that uses flying saucer to generate invoices (Spanish)

> **[GitHub - dagi3d/facturails: sencilla aplicación rails para generar facturas](https://github.com/dagi3d/facturails/tree/master)**
>
> master

All the best!

Robert W. escribiÃ³:

---

<div class="post-metadata">

**Author:** ![cool](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/c/c6cbf5/32.png) [@cool](https://www.ruby-forum.com/u/cool)\
**Post date:** [January 21, 2009, 4:42pm UTC](https://www.ruby-forum.com/t/download-a-content-as-a-pdf-format/158272/4 "2009-01-21T16:42:19Z")

</div>

cool wrote:

> Guys,

You can use gem available in ruby names as “pdf writer”

Enjoy
