# Send variables to PDF through php form \[GET?\]

**URL:** <https://forum.kirupa.com/t/send-variables-to-pdf-through-php-form-get/264197>\
**Category:** programming\
**Created:** [June 23, 2008, 10:55pm UTC](https://forum.kirupa.com/t/send-variables-to-pdf-through-php-form-get/264197 "2008-06-23T22:55:27Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Limitlis](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/limitlis/32/788_2.png) [@Limitlis](https://forum.kirupa.com/u/Limitlis)\
**Post date:** [June 23, 2008, 10:55pm UTC](https://forum.kirupa.com/t/send-variables-to-pdf-through-php-form-get/264197/1 "2008-06-23T22:55:27Z")

</div>

Please check out this example to see exactly what I’m talking about.  
[http://www.spreadfirefox.com/en-US/worldrecord/certificate?participant=Your%20Name%20Goes%20Here!](http://www.spreadfirefox.com/en-US/worldrecord/certificate?participant=Your%20Name%20Goes%20Here!)

Does anyone know how they do this? Is there an easy way to send variables to a pdf and display them into the form?

Any help appreciated.

Thanks!

---

<div class="post-metadata">

**Author:** ![evildrummer](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/evildrummer/32/2308_2.png) [@evildrummer](https://forum.kirupa.com/u/evildrummer)\
**Post date:** [June 23, 2008, 11:11pm UTC](https://forum.kirupa.com/t/send-variables-to-pdf-through-php-form-get/264197/2 "2008-06-23T23:11:24Z")

</div>

As far as I know it has to be done using a Server-Side language, I’ve had experience with dynamic PDF’s using PHP. I’ll try and find the library I used

---

<div class="post-metadata">

**Author:** ![Limitlis](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/limitlis/32/788_2.png) [@Limitlis](https://forum.kirupa.com/u/Limitlis)\
**Post date:** [June 24, 2008, 2:46pm UTC](https://forum.kirupa.com/t/send-variables-to-pdf-through-php-form-get/264197/3 "2008-06-24T14:46:23Z")

</div>

> [@evildrummer;2347972](#):
>
> As far as I know it has to be done using a Server-Side language, I’ve had experience with dynamic PDF’s using PHP. I’ll try and find the library I used

Yeah I figured that I might have to use and learn some sort of library :(. I was hoping that It would be easy like Flash to get variables from the address bar. Oh well.

If, you could still post the library that you used, maybe it’ll be different than the one’s that I’ve been looking at, like [FPDF](http://fpdf.org/).

Thanks again.

---

<div class="post-metadata">

**Author:** ![Charleh](https://avatars.discourse-cdn.com/v4/letter/c/a9a28c/32.png) [@Charleh](https://forum.kirupa.com/u/Charleh)\
**Post date:** [June 24, 2008, 3:18pm UTC](https://forum.kirupa.com/t/send-variables-to-pdf-through-php-form-get/264197/4 "2008-06-24T15:18:15Z")

</div>

FPDF looks quite simple to use, it’s got a lot of good documentation - I’d go ahead and use that

I mean the example is simple enough:

```auto

<?php
require('fpdf.php');
 
$pdf=new FPDF();
$pdf->AddPage();
$pdf->SetFont('Arial','B',16);
$pdf->Cell(40,10,'Hello World!');
$pdf->Output();
?>

```

Piece of cake!

---

<div class="post-metadata">

**Author:** ![evildrummer](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/evildrummer/32/2308_2.png) [@evildrummer](https://forum.kirupa.com/u/evildrummer)\
**Post date:** [June 24, 2008, 3:50pm UTC](https://forum.kirupa.com/t/send-variables-to-pdf-through-php-form-get/264197/5 "2008-06-24T15:50:44Z")

</div>

^^ I used FPDF, it was pretty simple, and it’s pretty easy to make a maintainable version.

---

<div class="post-metadata">

**Author:** ![ramie](https://avatars.discourse-cdn.com/v4/letter/r/edb3f5/32.png) [@ramie](https://forum.kirupa.com/u/ramie)\
**Post date:** [June 24, 2008, 5:04pm UTC](https://forum.kirupa.com/t/send-variables-to-pdf-through-php-form-get/264197/6 "2008-06-24T17:04:44Z")

</div>

[http://uk3.php.net/pdf](http://uk3.php.net/pdf)
