Support ⇒ Gamers Modules & Blocks ⇒ How do you receive ranks from the db? ⇒ Community Forums ⇒ CPG Dragonfly™ CMS
Forum Index Modules & Blocks Gamers Modules & Blocks

How do you receive ranks from the db? Reply to topic


Hey,

I have created a simple roster for my clan, showing the the member name, rank, and the awards the member has received. Now, since I have to edit the roster everytime some one gets a new rank, or changes the username, I'd appreciate it if some one could explain to me how to generate the username and the rank directly from the db, and then make it display in the roster. Also, it would be nice if some one could explain to me or point me to a documentation on how to make an admin interference for the roster, from which I can update the awards.

I appreciate your help,
Thx,
Heckler

P.s - link to my module obitusclan.com/dfly/in...me=webspec

Phone Rumors | My Solution Manuals | My Online Money Guide | Premium WordPress Themes

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Linux / 1.3.37 (Unix) / 4.1.21-standard / 4.4.6 / 9.2.1


If you're talking about the rank associated with the user account, it is actually pretty easy.

The table ${prefix}_bbranks contains all the ranks, including IDs. The rank a specific user has is determined by 2 things:

1. Whether or not the user has a special rank assigned. Special ranks always go first. This field is in ${user_prefix}_users, named user_rank. The content of this field is a special rank in the ranks table.
2. The number of posts the user has. This users the ${user_prefix}_users table as well, but this time the field user_posts. If there is no special rank assigned, the user will be assigned the rank that most closely matches their post count.

I don't believe this information is cached, but you can't be too sure, so always double check!

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
NetBSD 4.99.38 / Apache 2.2.6 / MySQL 5.0.45 / PHP 5.2.5 / DragonFly 9.1.2.1


Thx Very Happy I will try it out tonite Wink

Phone Rumors | My Solution Manuals | My Online Money Guide | Premium WordPress Themes

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Linux / 1.3.37 (Unix) / 4.1.21-standard / 4.4.6 / 9.2.1

All times are UTC


Jump to: