![]() |
Maximum 8 products in the shopping cart? - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: Maximum 8 products in the shopping cart? (/showthread.php?tid=54702) |
Maximum 8 products in the shopping cart? - El Forum - 09-20-2012 [eluser]Unknown[/eluser] Hello world! I have one question about the shopping cart, it works normally, but the maximum number of products stored product to cart is only 8, it is too little for my application So I want to ask how to configure to my shopping cart can store more than eight product? Thank you Maximum 8 products in the shopping cart? - El Forum - 09-20-2012 [eluser]skunkbad[/eluser] Store your session in the database or change the session encryption to something like blowfish so the encrypted session data isnt so big. Maximum 8 products in the shopping cart? - El Forum - 09-24-2012 [eluser]Unknown[/eluser] thank you, but you can tell more details?I still do not know what you mean Maximum 8 products in the shopping cart? - El Forum - 09-24-2012 [eluser]TWP Marketing[/eluser] What Brian is saying is that the shopping cart uses the Sessions library to store cart data and there is a limit on the size of cookies (4Kb) which can be stored locally. So, change to using database sessions (see the User Guide) which gives you virtually unlimited data space. It still uses a cookie, but the data itself is stored in a file on your server. The User Guide is your friend, sleep with it under your pillow and consult with it frequently. Maximum 8 products in the shopping cart? - El Forum - 09-24-2012 [eluser]skunkbad[/eluser] [quote author="TWP Marketing" date="1348501414"]What Brian is saying is that the shopping cart uses the Sessions library to store cart data and there is a limit on the size of cookies (4Kb) which can be stored locally. So, change to using database sessions (see the User Guide) which gives you virtually unlimited data space. It still uses a cookie, but the data itself is stored in a file on your server. The User Guide is your friend, sleep with it under your pillow and consult with it frequently.[/quote] And the other side of what I suggested is that the session encryption be changed to something that doesn't produce strings that are 10 times the size of the original data. By default CodeIgniter uses MCRYPT_RIJNDAEL_256, but if you change it to MCRYPT_BLOWFISH the size of the data becomes way smaller. I do this in MY_Encrypt.php Code: <?php if( ! defined('BASEPATH') ) exit('No direct script access allowed'); Maximum 8 products in the shopping cart? - El Forum - 09-24-2012 [eluser]CroNiX[/eluser] Seems like a good thing to be added into the core for the main config settings (encryption algorithm) Maximum 8 products in the shopping cart? - El Forum - 09-24-2012 [eluser]skunkbad[/eluser] [quote author="CroNiX" date="1348515217"]Seems like a good thing to be added into the core for the main config settings (encryption algorithm)[/quote] Yeah, it does seem kinda ridiculous to have to extend the Encrypt class just for this. |