Re: [PHP] Images in PHP and MySQL
No problem Ed thanks... Actually I was supprised to see this conversation (thread) come back into my GMAIL inbox On Wed, 6 Oct 2004 15:57:12 -0700, Ed Lazor [EMAIL PROTECTED] wrote: On Friday 01 October 2004 05:52, Ed Lazor wrote: Images take up more space when stored in the db, because you're storing raw binary data. Gif and jpeg are compression methods that convert binary data into something smaller that can be stored in a file. ?? If you store a jpeg file into a database blob, the database doesn't magically decompress the jpeg file. It will just treat the jpeg file as any other binary file and store it as-is (plus any overhead). Sorry for not responding sooner - just found this message while cleaning on my PHP folder. Anyway, we're both right, depending on how you go about saving the images to the database. You're talking about using PHP's file functions to open the image file, read in the data, and stream it to the database. I'm talking about using the built-in GD functions to grab the image (like imagecreatefromjpeg) and store it into the database. As you're pointing out, the GD functions are performing the compression and decompression. This was part of another discussion GH and I were having on the MySQL list about different approaches to storing large collections of images. Sorry, I should have mentioned that. -Ed -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Question about handling credit cards
Could you provide more information, code example or a how to to do this.. Thanks On Mon, 04 Oct 2004 15:03:31 -0700, Matthew Fonda [EMAIL PROTECTED] wrote: The best way to store credit card numbers is to have them encrypted when they are stored in the database, and decrypted when they need to be used, that way it will be safer for the most part On Mon, 2004-10-04 at 14:49, Ed Lazor wrote: I'm looking at online stores and it seems like a lot of them maintain copies of credit card numbers. Is this true? That seems like a bad thing to me, especially in terms of liability and risk of hackers. On the flip side, it seems like there are legitimate reasons. For example, if you bill the customer when products ship, rather than when the order is received. Or, if the customer decides to have instock items ship now and back ordered items ship when they arrive - which results in two shipping charges. How do you guys handle this? -Ed -- Regards, Matthew Fonda -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php