PhotoPost Photo Gallery Sales PhotoPost Sales Toll Free Phone Number
Mon-Fri 9am-4pm EST
  PhotoPost Photo Sharing Photo Gallery    Visualize community tm
| | | | | | | | |
Old February 11th, 2005, 05:53 PM   #1 (permalink)
Member
Verified Customer
 
Join Date: Nov 2002
Posts: 398
Add Gallery Stats to Home Statistics

http://www.vbadvanced.com/forum/showthread.php?t=3558

You helped me do this for the links module, but how do I do this for the gallery program...

I'm not sure of what the query should be...

Thanks for your help...

InterFX
InterFX is offline   Reply With Quote
Old February 13th, 2005, 05:41 PM   #2 (permalink)
Member
Verified Customer
 
Join Date: Nov 2002
Posts: 398
Re: Add Gallery Stats to Home Statistics

This is how Brian suggested it in VBaLinks...

$totallinks = $DB_site->query_first("SELECT COUNT(*) AS count FROM " . TABLE_PREFIX . "links WHERE valid = 1 AND suspended = 0");

$totallinks = number_format($totallinks['count']);

Anyone understand this enough, and table structure for Gallery?

Any ideas?

InterFX
InterFX is offline   Reply With Quote
Old February 13th, 2005, 05:45 PM   #3 (permalink)
Ultimate Member
Verified Customer
 
ConqSoft's Avatar
 
Join Date: Nov 2003
Location: Raleigh, NC
Posts: 1,413
Re: Add Gallery Stats to Home Statistics

Try:

$totalimages= $DB_site->query_first("SELECT COUNT(*) AS count FROM " . TABLE_PREFIX . "images WHERE valid = 1");

$totalimages= number_format($totalimages['count']);
ConqSoft is offline   Reply With Quote
Old February 13th, 2005, 06:10 PM   #4 (permalink)
Member
Verified Customer
 
Join Date: Nov 2002
Posts: 398
Re: Add Gallery Stats to Home Statistics

I tried that, but it didn't work... It seems the table is called something else than "xxxxxx.images"... I'll keep trying if you have other ideas...

Thanks -
InterFX

Database error in vBulletin 3.0.6:

Invalid SQL: SELECT COUNT(*) AS count FROM images WHERE valid = 1
mysql error: Table 'xxxxxx.images' doesn't exist

mysql error number: 1146
InterFX is offline   Reply With Quote
Old February 13th, 2005, 06:15 PM   #5 (permalink)
Ultimate Member
Verified Customer
 
ConqSoft's Avatar
 
Join Date: Nov 2003
Location: Raleigh, NC
Posts: 1,413
Re: Add Gallery Stats to Home Statistics

It's called adv_gallery_images by default. Not sure about the prefix part with Gallery, so you should be able to hard code the table name.

$totalimages= $DB_site->query_first("SELECT COUNT(*) AS count FROM adv_gallery_images WHERE valid = 1");
ConqSoft is offline   Reply With Quote
Old February 13th, 2005, 06:18 PM   #6 (permalink)
Member
Verified Customer
 
Join Date: Nov 2002
Posts: 398
Re: Add Gallery Stats to Home Statistics

Hey, that worked GREAT!!!

Thanks for your help...
InterFX is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I add the Random Images Block to my home page mackers8923 Photopost Pro How Do I...? 3 December 17th, 2005 07:24 PM
Add most recent images to home page (php file) stmpspaz Photopost Pro How Do I...? 5 October 26th, 2005 08:13 AM
HowTo add navbar link on home deb0 How Do I? - vBulletin 3.0.X 2 December 16th, 2004 11:25 AM


All times are GMT -5. The time now is 03:24 AM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0