Jump to content

Products per page


art15

Recommended Posts

Hi All,

 

I have a script in place which write products per page from the value defined in the admin panel for products per page. (for eg: if it is specified inside the admin panel as 15 per page, the web will show 15 products per page). I was looking to put a drop down on web for the user to select the products per page. I tried few things and somewhere I got for one user by updating the database with the drop down value the user selects but this way if there is some other user selecting different option the database will update itself and will be a problem every time. Can any one suggest how this can be done.

 

 

Thanks

Link to comment
https://forums.phpfreaks.com/topic/104157-products-per-page/
Share on other sites

If you already have the database up and running you could add another column to the user information to retain the products per page info. Just add another variable to the session to follow this information during a user visit.

 

Hi DyslexicDog,

Thanks for your reply. do you mean that I need to add another column to the database to hold the value or you mean creating a variable in php to hold this value?. I have a variable called $perpage which takes value from database and divides the total products by $perpage. I want the user to control this without updatin the $perpage value.

 

Thanks

Link to comment
https://forums.phpfreaks.com/topic/104157-products-per-page/#findComment-533231
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.