0))) { // Use last online timestamp to keep inactive members away from here $lastOnline = ' AND (UNIX_TIMESTAMP() - `last_online`) < {?ap_inactive_since?}'; } // END - if // Let's check if there are some points left we can pay... $result = sqlQueryEscaped("SELECT `userid`, `beg_points`, `last_online` FROM `{?_MYSQL_PREFIX?}_user_data` WHERE `beg_points` > 0 AND `status`='CONFIRMED' " . runFilterChain('user_exclusion_sql', ' ') . " " . $lastOnline . " ORDER BY `beg_points` DESC, `last_online` DESC, `userid` ASC LIMIT {?beg_ranks?}", array( $ONLINE ), __FILE__, __LINE__); // Reset temporary variable and check for users $OUT = ''; if (!ifSqlHasZeroNums($result)) { // Load our winners... $count = 1; while ($content = sqlFetchArray($result)) { // Prepare data for the template $content['count'] = $count; $content['last_online'] = generateDateTime($content['last_online'], '2'); // Load row template $OUT .= loadTemplate('member_list_beg_row', TRUE, $content); // Count one up $count++; } // END - while } else { // No one is interested in our "begging rallye" ! :-( $OUT = loadTemplate('member_beg_404', TRUE); } // Prepare content $content['rows'] = $OUT; // Free memory sqlFreeResult($result); // Load final template loadTemplate('member_list_beg', FALSE, $content); // [EOF] ?>