Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Total amount of products on site


Lalla

Recommended Posts

Is there a contribution that will show a total of inventory in your store. I know that I can click on the different categories and add their amounts together, but when I upload a group of books, I would sure like to make sure that all went thru.

 

Thanks,

Lalla

Link to comment
Share on other sites

Hi,

 

this should do the job, just add this wherever:

 

There are currently <?php 
$sql = "SELECT COUNT(*) AS Total FROM products"; $query = mysql_query($sql); $data=mysql_fetch_array($query); echo $data['Total']; 
?> products available in <?php 
$sql = "SELECT COUNT(*) AS Total FROM categories"; $query = mysql_query($sql); $data=mysql_fetch_array($query); echo $data['Total']; 
?> categories.

 

It should return someting like:

 

There are currently 194 products available in 17 categories.

Link to comment
Share on other sites

Is there a contribution that will show a total of inventory in your store. I know that I can click on the different categories and add their amounts together, but when I upload a group of books, I would sure like to make sure that all went thru.

 

Thanks,

Lalla

Hi Lalla - long time since I've seen you on here. :)

 

Here is a contribution I just uploaded to do this. It only displays it in admin. If the option is needed to display it in the catalog section is needed, let me know as it will be an easy change.

 

Jack

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...