3 Replies - 721 Views - Last Post: 02 April 2013 - 11:15 AM Rate Topic: -----

#1 James1992  Icon User is offline

  • D.I.C Head

Reputation: 3
  • View blog
  • Posts: 130
  • Joined: 30-October 12

Displaying Image stored in myphpadmin on dreamweaver

Posted 02 April 2013 - 02:31 AM

I currently have a couple of images stored as a blob type in myphpadmin.

I have created a record set on dreamweaver and have a dynamic table to display all the images and other attributes.
The attributes are shown fine however the image is just a bunch of random characters.

what do you reckon could be the problem?
Is This A Good Question/Topic? 0
  • +

Replies To: Displaying Image stored in myphpadmin on dreamweaver

#2 Dormilich  Icon User is online

  • 痛覚残留
  • member icon

Reputation: 3541
  • View blog
  • Posts: 10,256
  • Joined: 08-June 10

Re: Displaying Image stored in myphpadmin on dreamweaver

Posted 02 April 2013 - 03:23 AM

from the description Id stab a guess at the wrong MIME type. images must be served as (e.g.) "image/png" not as "text/html" (HTML text), which is the default on most webservers.
Was This Post Helpful? 0
  • +
  • -

#3 James1992  Icon User is offline

  • D.I.C Head

Reputation: 3
  • View blog
  • Posts: 130
  • Joined: 30-October 12

Re: Displaying Image stored in myphpadmin on dreamweaver

Posted 02 April 2013 - 08:21 AM

View PostDormilich, on 02 April 2013 - 03:23 AM, said:

from the description Id stab a guess at the wrong MIME type. images must be served as (e.g.) "image/png" not as "text/html" (HTML text), which is the default on most webservers.


For test purposes I have created a separate table within phpmyadmin with 2 attributes. They are:

ID, INT (primary key and Auto increment)
Image, Blob

I have inserted a row. For testing purposes I have also got a blank PHP page. I have created recordset and inserted a dynamic table. I still have the same problem as before as I haven't changed anything as of yet. This is what it looks like in the browser.

http://i45.tinypic.com/20z9ncl.png

So I need to change the MIME type? How would I go about changing this?
Was This Post Helpful? 0
  • +
  • -

#4 Dormilich  Icon User is online

  • 痛覚残留
  • member icon

Reputation: 3541
  • View blog
  • Posts: 10,256
  • Joined: 08-June 10

Re: Displaying Image stored in myphpadmin on dreamweaver

Posted 02 April 2013 - 11:15 AM

View PostJames1992, on 02 April 2013 - 04:21 PM, said:

So I need to change the MIME type? How would I go about changing this?

youd use the header() function for that.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1