yoda69 Posted April 7, 2010 Share Posted April 7, 2010 Hi, I have a table (100 x 100 - coming out of a database) with every cell filled with a different color. Is there a way using a php function so the client actually see the table as an image? Thanks, Link to comment https://forums.phpfreaks.com/topic/197859-convert-html-table-to-an-image-using-php/ Share on other sites More sharing options...
tomtimms Posted April 7, 2010 Share Posted April 7, 2010 no, unless you take a screen shot of the table and save it as a jpg. You can't to my knowledge take CODE and cover it to a jpg/gif without some type of software converter. Link to comment https://forums.phpfreaks.com/topic/197859-convert-html-table-to-an-image-using-php/#findComment-1038328 Share on other sites More sharing options...
yoda69 Posted April 7, 2010 Author Share Posted April 7, 2010 What about the function: imagecreatefromstring() Don't really know how to use it but do you think it will be possible? Link to comment https://forums.phpfreaks.com/topic/197859-convert-html-table-to-an-image-using-php/#findComment-1038330 Share on other sites More sharing options...
yoda69 Posted April 7, 2010 Author Share Posted April 7, 2010 Do you know any script that can take a snapshot of the table? Link to comment https://forums.phpfreaks.com/topic/197859-convert-html-table-to-an-image-using-php/#findComment-1038348 Share on other sites More sharing options...
litebearer Posted April 7, 2010 Share Posted April 7, 2010 Have you considered convert the table to a pdf file? Link to comment https://forums.phpfreaks.com/topic/197859-convert-html-table-to-an-image-using-php/#findComment-1038359 Share on other sites More sharing options...
maca134 Posted April 7, 2010 Share Posted April 7, 2010 you will have to draw the table if you use the PHP image functions. Finding a "HTML -> PDF" PHP is going to be much easier. try looking on www.phpclasses.org, its a great website for PHP classes Link to comment https://forums.phpfreaks.com/topic/197859-convert-html-table-to-an-image-using-php/#findComment-1038364 Share on other sites More sharing options...
yoda69 Posted April 7, 2010 Author Share Posted April 7, 2010 Okay, thanks for that tip. Why would it be easier to convert html -> pdf. than html -> gif? Link to comment https://forums.phpfreaks.com/topic/197859-convert-html-table-to-an-image-using-php/#findComment-1038369 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.