The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#6
|
|||
|
|||
![]()
That depends on what you're trying to do. If you just want to make a static html file with your current top 30, then you'd put that query (line 1) in phpMyAdmin and copy the results, if you want to make a dynamic richest.php, then you take the code I put above, and put it in a file that connects to the database.
To explain the code: line 1: This is the query to the database. You're searching all users, ordering by the money field, sorting in descending order, and then take the first 30 positions after 0 (aka the first 30). line 2: This is a while statement that will parse through all 30 of your results. As in, this chunk of code will get called 30 times since we're going to have 30 results from teh previous query. line 3: echo() is just a function that will print the following string to the user, so you're printing "USERNAME has # money.<br>". This would return 30 lines, with USERNAME and # replaced with the top 30 users. Just for formatting purposes, you might want to start a table. Something like: <table> <tr><td>User</td><td>Money</td></tr> then your echo string would be "<tr><td>$user[username]</td><td>$user[money</td></tr>"; then close your table with: </table> I'm not sure how much HTML you know, but you can pretty up the table as you see fit with the rest of the page. |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|