3 * User Invites and Points FAQ
5 * @author Anthony Parsons (xmpp:ant@specialops.ath.cx)
6 * @license file://COPYING
10 $prefetch = array('`points`', '`invites`');
12 $page->title
= 'Stuff Control Panel';
14 if ( ! ($user instanceof User_Authenticated
) ) {
15 $page->errorfooter('login');
20 echo "<h2>User Invites</h2>\n";
22 if ( !defined('INVITE_ONLY') ) {
23 echo '<p class="info">Invites are currently disabled.</p>',"\n";
25 $urllist = $DB->query('SELECT `data` FROM `things` WHERE `what` = "invite" AND `userid` = @userid');
26 if ( $urllist->num_rows
) {
27 echo "<h3>Invite Links:</h3>\n<ul>\n";
29 while ( list($code) = $urllist->fetch_row() ) {
30 printf(' <li><a href="register?user=%d;code=%s">http://%s%s/register?user=%1$d;code=%2$s</a></li>'."\n",
31 $user->userid
, $code, $_SERVER['HTTP_HOST'], dirname($_SERVER['REQUEST_URI']));
35 '<p>These links are only valid for one registration, and you can only have a maximum of 5 at any time.</p>',"\n";
38 for ( $i = max($user->points
, pow($user->invites
, 2)); floor(sqrt($i)) != sqrt($i); $i++
);
40 echo '<p class="info">Points to next invite: ',($i - $user->points
),"</p>\n";
42 $userlist = $DB->query('SELECT `userid`, `alias` FROM `users` WHERE `referrer` = @userid');
43 if ( $userlist->num_rows
) {
44 echo "<h3>You have invited:</h3>\n<ol>\n";
46 while ( $user2 = $userlist->fetch_row() ) {
47 echo ' <li>',$user->namelink($user2[0], $user2[1]),"</li>\n";
56 <p
class="info">You have
<?php
echo $user->points ?
> points
.</p
>
59 <li
>Topics
: +
2 points each
</li
>
60 <li
>Posts
: +
1 point each
</li
>
64 <li
>1 point
: You can mark messages
, but it has no effect on their score
.</li
>
65 <li
>10 points
: You can mark messages up
/down
for 1 point each
.</li
>
66 <li
>100 points
: Message marks are now worth
2 points
.</li
>
67 <li
>1000 points
: Marks are worth
3 points
.</li
>
68 <li
>10000 points
: Marks are
4 points plus you can
use HTML in posts
.</li
>