Page 1 of 1
Generate PDF from base64 string
Posted: 11 May 2015, 13:16
by joshuatan17
Hi there,
I'm wondering if there's a way to generate PDF from base64 string?
$data = some base64 encoding;
echo '<img src="data:image/png;base64,' . $data . '" />';
Re: Generate PDF from base64 string
Posted: 14 May 2015, 00:37
by Jan
Hi, not sure what you exactly mean?
Jan
Re: Generate PDF from base64 string
Posted: 14 May 2015, 03:10
by joshuatan17
Hi Jan,
I want to generate an article with images. But instead of image files within the article, I want to use base64 encoding to echo the image. Is that possible?
For example...
$data = some base64 encoding;
echo '<img src="data:image/png;base64,' . $data . '" />';
(I'm embedding PHP inside the article)
Re: Generate PDF from base64 string
Posted: 17 May 2015, 11:26
by Jan
Hi, now I understand, but I think, TCPDF class (PDF feature) does not support this way of displaying images like internet browsers do
(but I am really not sure)
Jan