anthonydamasco Posted March 12, 2007 Share Posted March 12, 2007 Hey, I'm looking for a script that will generate a PDF from a MySQL database. Link to comment https://forums.phpfreaks.com/topic/42400-pdf-php-and-mysql/ Share on other sites More sharing options...
only one Posted March 12, 2007 Share Posted March 12, 2007 ok ive never done this with a pdf before but ill see if i can get something to work... select for your table what you want using mysql... <?php $result = mysql_query(SELECT * FROM your tabel); // you have to edit this $row = mysql_fetch_array($result); $text = $row['text']; $filename = "file.pdf"; //name of file $file=fopen($filename,'w+'); //open file fwrite($file,$_POST[text]); //write to file fclose($file);//close file ?> should work.. i hope :S Link to comment https://forums.phpfreaks.com/topic/42400-pdf-php-and-mysql/#findComment-205722 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.