MyBB Community Forums
[Download] MyBB Statistics Signature - Printable Version

+- MyBB Community Forums (https://community.mybb.com)
+-- Forum: Extensions (https://community.mybb.com/forum-201.html)
+--- Forum: Plugins (https://community.mybb.com/forum-73.html)
+---- Forum: Plugin Releases (https://community.mybb.com/forum-102.html)
+---- Thread: [Download] MyBB Statistics Signature (/thread-52673.html)

Pages: 1 2 3 4 5 6 7


[Download] MyBB Statistics Signature - Eric - 2009-07-09

So, um, I was tired of not knowing how to get a statistics signature for my website, so I finally decided to look for how to do it, and I did. Thanks to http://php.net I can finally do it, and I don't want everyone else to be in the dark as well, so here is a free download on how to do it, not really a tutorial, but I didn't know where else to put this. :/


Just so people know, it's to make a signature like the one I have.

Also, statsig2 has the information reversed, as in, it has the link at the top of the sig and the information at the bottom.


RE: [Download] MyBB Statistics Signature - Matt - 2009-07-09

More a plugin that a tutorial really, moved to releases Smile

One thing I will say though is this... instead of doing:

//This Calculates Your Total Posts
$total_posts_query = mysql_query("SELECT * FROM ".TABLE_PREFIX."posts");
$total_posts = mysql_num_rows($total_posts_query);

//This Calculates Your Total Members
$total_members_query = mysql_query("SELECT * FROM ".TABLE_PREFIX."users");
$total_members = mysql_num_rows($total_members_query);

//This Calculates Your Total Threads
$total_threads_query = mysql_query("SELECT * FROM ".TABLE_PREFIX."threads");
$total_threads = mysql_num_rows($total_threads_query);

Maybe do:

//This Calculates Your Total Posts
$total_posts = mysql_query("SELECT COUNT(*) FROM ".TABLE_PREFIX."posts");

//This Calculates Your Total Members
$total_members = mysql_query("SELECT COUNT(*) FROM ".TABLE_PREFIX."users");

//This Calculates Your Total Threads
$total_threads = mysql_query("SELECT COUNT(*) FROM ".TABLE_PREFIX."threads");

Otherwise you'll have a huge array of all of the posts, users and threads, this should be much faster.


RE: [Download] MyBB Statistics Signature - Eric - 2009-07-09

K, thanks, I'm not that great at PHP, just looked it up to make this, so yeah, I'll change the download real quick. Wink

I also gave you credit for the help in the file.


RE: [Download] MyBB Statistics Signature - Gene53 - 2009-07-10

Nice work in progress, may I suggest that the forum name be on the first line and the stats on the 2nd?


RE: [Download] MyBB Statistics Signature - Eric - 2009-07-10

Alright, well, I'll make that an alternate download, however, it's pretty easy to do yourself. xD


RE: [Download] MyBB Statistics Signature - Rafael - 2009-07-10

How many queries makes this plugin?, how this plugin works?, well, when it makes the thread count?.

I think this plugin is good, but maybe server intensive. ¿?


RE: [Download] MyBB Statistics Signature - Lennart Sauter - 2009-07-10

Looks to me as if you'd have 3 huge queries every time the image is displayed - that will stress the server...

I think Labrocca's way to use the cache is much better...


RE: [Download] MyBB Statistics Signature - Eric - 2009-07-10

Like I said, I'm not that great with PHP, I just read up to make this. :/


RE: [Download] MyBB Statistics Signature - querschlaeger - 2009-07-10

Hi,

what's the licence of this file? Maybe we can work together to perfect it. If it's a free licence (for example GPLv3?) I would contribute some caching possibilities. Wink


RE: [Download] MyBB Statistics Signature - Eric - 2009-07-10

I haven't went into License specifics yet, however, I don't want a link to the Pharmaboards in it. Toungue