8, January 2009

Question about PDF and php - webmaster forum

 
Webdigity webmaster forums
This forum shares its ad revenue with its members!
[ Home | Help | Search | Forum's Shop | Archive | Login | Register | Webmaster Directory ]
Webdigity Webmaster Forums  >  Web Development  >  PhP
Topic: Question about PDF and php
« previous next »
Pages: [1] Print

Author Topic: Question about PDF and php  (Read 702 times)
Sandwich Artist
*
Posts: 25
186 credits
Members referred : 0


« on: Mar 12, 2008, 10:13:55 PM »

Does any one know if its possible to take variables from PHP and insert them into a PDF document?  I'm working on something now that would make things a lot easier if this was possible?  Any ideas
Global Moderator
Community Supporter ?
Jedai Sword Master
*****
Gender: Male
Posts: 6557
40174 credits
Members referred : 374


It's time to use PHP5!


« Reply #1 on: Mar 13, 2008, 12:16:49 AM »

check fpdf.org or search for fpdi to add content to existing pdfs


Last blog : Just a better Internet portal provided by Google
My name is Bong, James Bong
*
Posts: 10
96 credits
Members referred : 0


« Reply #2 on: Apr 30, 2008, 08:08:47 PM »

i don't have much idea about this.
you should try with google to solve .


<snip /> go away spammer!
« Last Edit: Apr 30, 2008, 08:34:54 PM by Olaf »
What a dork
*
Posts: 16
116 credits
Members referred : 1


« Reply #3 on: May 26, 2008, 11:13:29 PM »

Dynamic pdf documents with PHP
R&OS: pdf class
http://www.ros.co.nz/pdf/ Visit through proxy

HTML to PDF converter
http://www.digitaljunkies.ca/dompdf/about.php#overview Visit through proxy
I love Pokemon
*
Posts: 13
86 credits
Members referred : 0



« Reply #4 on: May 27, 2008, 01:29:36 PM »

<?php
// create handle for new PDF document
$pdf = pdf_new();
// open a file
pdf_open_file($pdf, "philosophy.pdf");
// start a new page (A4)
pdf_begin_page($pdf, 595, 842);
// get and use a font object
$arial = pdf_findfont($pdf, "Arial", "host", 1); pdf_setfont($pdf, $arial, 10);
// print text
pdf_show_xy($pdf, "There are more things in heaven and earth, Horatio,",50, 750);
pdf_show_xy($pdf, "than are dreamt of in your philosophy", 50,730);
// end page
pdf_end_page($pdf);
// close and save file
pdf_close($pdf);
?>

Save this file, and then browse to it through your Web browser. PHP will execute the script, and a new PDF file will be created and stored in the location specified at the top of the script.

Trackback URI for this entry : http://www.webdigity.com/trackback.php?topic=7654
Tags : php pdf Bookmark this thread : Digg Del.icio.us Dzone more....

Topic sponsors:
Get a permanent link here for $1.99!


Pages: [1] Print 
Webdigity Webmaster Forums  >  Web Development  >  PhP
Topic: Question about PDF and php
« previous next »
Jump to:
User Area
Welcome, Guest. Please login or register.
Did you miss your activation email?
Jan 08, 2009, 09:31:51 PM





Login with username, password and session length

Donate to our community, and get a permanent link back to your site!

Donate to our community, and get a permanent link back to your site!


Forum Statistics
Total Posts: 38.657
Total Topics: 7.772
Total Members: 4.659
Tutorials : 56
Resources : 143
Designs : 220
Latest Member: sardiniasarena

25 Guests, 4 Users online :

17 users online today:



Readers

Web Design Gallery · Whois Lookup · Pagerank · Tag Browsing · Lo-fi version · Syndication · Webmaster forum history · Advertise
Developed by HumanWorks © 2005 - 2009 Webdigity webmaster community · sublime directory
Webdigity Webmaster Forums | Powered by SMF 1.0.12. © 2001-2005, Lewis Media. All Rights Reserved.