Storing binary data in mySQL

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I have a minor issue with storing specific types of data in a blob field in mySQL.


I am working with PDO, and while it seems to work alright with image files, etc., if I try to store a sound clip in the database, using exact same code, etc., when I then pull the data out of the database again, setting content-disposition, file name, content-type, etc. back to match the original values, the audio clips seem to get corrupted when being extracted?


Any thoughts on what I need to bear in mind/try while extracting, or storing the data?


Can also post the code here, but, thought would first just ask, since when I do the exact same thing with image files, they seem fine when they then get extracted/rendered.


Suppose should also try some other file types, like documents, PDF files, etc., just to test, but, just find it a bit odd that one type of file - .jpg, .gif, or .png - works fine, but, others, like .wav, .mp3 and .ogg don't want to cooperate.


TIA


Jacob Kruger
Blind Biker
Skype: BlindZA
"Resistance is futile, but, acceptance is versatile..."


--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[Index of Archives]     [PHP Home]     [PHP Users]     [PHP Database Programming]     [PHP Install]     [Kernel Newbies]     [Yosemite Forum]     [PHP Books]

  Powered by Linux