Re: User-friendly approaches to displaying subtable data
Posted by: Rick James
Date: June 25, 2013 10:12PM

There are three ways to deal with images...

1.
Convert to base64, stick inside
<img src="data:image/png;base64,...">

2.
(Assuming you are using PHP)
Let another program do the work. (This is arguably the 'right' way.):
Your program emits
<img src="foo.php?id=123">
Then you have a program called foo.php that takes the 'id' argument, connects to the database, and fetches image #123, then emits it...
Start with a
header('Content-type: image/jpeg');
and end with one of the imagejpeg functions.

3.
Don't put images in the table, instead have them in separate files.
In the output, simply refer to the file:
<img src=blah.jpg>

Options: ReplyQuote




Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.