MySQL Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsDatabasesMySQL Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
Stay one step ahead of the competition. Evaluate and give feedback on some of the hottest web development tools on the market today. Make your opinion heard! Click Here
  #1  
Old February 15th, 2005, 01:27 AM
Capt Morgan Capt Morgan is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2005
Posts: 4 Capt Morgan User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 2 m 47 sec
Reputation Power: 0
Post Storing Images in MySQL

Hi All,
I wanna know how to store images (gif/jpg only) in MySQL.
the MySQL db is being accesed via a PHP web Application.

Hoping for your support

Reply With Quote
  #2  
Old February 15th, 2005, 04:11 PM
aduroris aduroris is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2005
Posts: 7 aduroris User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 18 m 29 sec
Reputation Power: 0
Hi,

You shouldn't store images in a database, but rather link them to the database.

This will save a lot of time.

Best regards,
Dustin J. Cox

Reply With Quote
  #3  
Old February 16th, 2005, 08:04 AM
MadCowDzz's Avatar
MadCowDzz MadCowDzz is offline
I'm Internet Famous
Dev Articles Frequenter (2500 - 2999 posts)
 
Join Date: Jan 2003
Location: Toronto, Canada
Posts: 2,890 MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level)MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level)MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level) 
Time spent in forums: 1 Week 16 h 4 m 48 sec
Reputation Power: 8
I don't know if saying one shouldn't store images in a database is a good suggestion...
It is possible, and in some cases would prove quite useful...

Personally, I try not to; I would prefer to store the images in a certain directory on the server, and provide that location as a String/Varchar in the database.

That being said, it is completely possible to store images in a table as a BLOB.

Here's a quick tutorial on a different site that I've found... Create Thumbnail in PHP and database BLOB
The site seems to have messed up the HTML entities, so that might make it tough to copy&paste the code... use it more as a guide

Reply With Quote
  #4  
Old February 16th, 2005, 08:11 AM
MadCowDzz's Avatar
MadCowDzz MadCowDzz is offline
I'm Internet Famous
Dev Articles Frequenter (2500 - 2999 posts)
 
Join Date: Jan 2003
Location: Toronto, Canada
Posts: 2,890 MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level)MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level)MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level) 
Time spent in forums: 1 Week 16 h 4 m 48 sec
Reputation Power: 8
I just realized this is a double post... [i knew i answered this question yesturday]
Refer to the other thread for other answers

Avoid posting in seperate forums...
you'll get better results with a single thread in the proper forum...

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsDatabasesMySQL Development > Storing Images in MySQL


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway