#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2000
    Posts
    3
    Rep Power
    0
    Is it possible to store jpegs into a MySQL database, so it can be loaded when PHP requests it?? If not, which database (for Win/Linux) can?
    thanx
  2. #2
  3. Banned (not really)
    Devshed Supreme Being (6500+ posts)

    Join Date
    Dec 1999
    Location
    Brussels, Belgium
    Posts
    14,646
    Rep Power
    4492
    Yes
  4. #3
  5. No Profile Picture
    Carpe Diem
    Guest
    Devshed Newbie (0 - 499 posts)
    You can use MySQL but its much better to use the MySQL database to store the paths to the images rather then the actual images




    ------------------
    Regards
    Darren
    --
    http://www.php4hosting.com/ $
    http://www.php4hosting.co.uk/
    PHP/MySQL Enabled Hosting/Dedicated Servers, Reseller Accounts
  6. #4
  7. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2000
    Posts
    3
    Rep Power
    0
    Thank you both! Can anybody tell me how to store it? Using SQL queries in php? or is it another way than storing just chars and strings
  8. #5
  9. Banned (not really)
    Devshed Supreme Being (6500+ posts)

    Join Date
    Dec 1999
    Location
    Brussels, Belgium
    Posts
    14,646
    Rep Power
    4492
    Just do a search on here or phpbuilder.com. This question has been answers many many times. There are tutorials on both sites telling you how to do it also.

    I agree with Carpe Diem, of course, just store the path to the file in mysql. Why go through the extra database overhead to retrieve a file when php has functions designed to do it for you?

    ---John Holmes..
  10. #6
  11. No Profile Picture
    chinnavi
    Guest
    Devshed Newbie (0 - 499 posts)
    hai
    i will tell u the logic alone ....
    i have done this using PERL ...
    But no idea with PHP ...

    1. Open the GIF IMAGE ... using File open
    2. Store the content of the image in one valiable by iteration ...
    3. Then Connect to the Database ..
    4. SET SQL ...
    5. Add to Database...

    Still have problems?

    vijay
  12. #7
  13. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2000
    Posts
    3
    Rep Power
    0
    Thank you all! will give it a try

Similar Threads

  1. Mysql problem.
    By Nik in forum MySQL Help
    Replies: 54
    Last Post: December 21st, 2006, 07:02 PM
  2. Storing a forum message in a mysql db field
    By paulvinten in forum MySQL Help
    Replies: 1
    Last Post: January 7th, 2004, 10:05 PM
  3. Upgrade from access to mysql
    By karib1 in forum ASP Programming
    Replies: 7
    Last Post: December 16th, 2003, 01:35 PM
  4. Upgrade from access to mysql
    By karib1 in forum MySQL Help
    Replies: 1
    Last Post: December 16th, 2003, 01:27 AM

IMN logo majestic logo threadwatch logo seochat tools logo