Exemplo n.º 1
0
?>
 Profile" title="<?php 
echo $user['username'];
?>
 Profile"><?php 
echo $user['username'];
?>
</a></h4>
							<table class="table table-condensed borderless thin marg-bot-0">
								<tr>
									<td class="col-xs-3">
										<small><small><a href="http://www.JPVocab.com/player.php?player=<?php 
echo $user['username'];
?>
&report=flashcardrank">Flashcard Ranking</a>: <?php 
echo ordinal(getUserFCardRank($user['id']));
?>
</small>
									</td>
									<td>
										<small>Currently Practicing
										<a href="<?php 
echo getDeckFullUrl(getSkill('cvset', $user['id']));
?>
">
											<?php 
echo getDeckInfo(getSkill('cvset', $user['id']), 'display_name');
?>

										</a></small>
									</td>
Exemplo n.º 2
0
<?php

include_once "include/check_login.php";
if ($user_ok == false) {
    header("location: restricted.php?refPage=lobby");
    exit;
}
require_once 'words.php';
require_once 'stats.php';
require_once 'config.php';
$conn = mysql_connect($dbhost, $dbuser, $dbpass) or die('Error connecting to mysql');
mysql_select_db($dbname);
mysql_query("SET NAMES UTF8");
$userID = getUserID($_SESSION['username']);
$fcrank = getUserFCardRank($userID);
$ttldks = getStat('ttldks', $userID);
$ttlpvstyl = getStat('ttlpvstyl', $userID);
$fcrankFA = $fcrank > 50 ? '<i class="fa fa-frown-o text-danger"></i>' : ($fcrank > 25 ? '<i class="fa fa-meh-o"></i>' : ($fcrank <= 25 ? '<i class="fa fa-smile-o text-success"></i>' : ''));
$dksFA = $ttldks < 3 ? '<i class="fa fa-frown-o text-danger"></i>' : ($ttldks >= 3 && $ttldks < 7 ? '<i class="fa fa-meh-o"></i>' : ($ttldks >= 7 ? '<i class="fa fa-smile-o text-success"></i>' : ''));
$vstylFA = $ttlpvstyl < 3 ? '<i class="fa fa-frown-o text-danger"></i>' : ($ttlpvstyl >= 3 && $ttlpvstyl < 7 ? '<i class="fa fa-meh-o"></i>' : ($ttlpvstyl >= 7 ? '<i class="fa fa-smile-o text-success"></i>' : ''));
if ($ttldks == 0) {
    $ttldks = countUserDecks($userID);
    setStat('ttldks', $userID, $ttldks);
}
//make sure db is correc
if ($ttlpvstyl == 0) {
    $ttlpvstyl = countUserVStyle($userID);
    setStat('ttlpvstyl', $userID, $ttlpvstyl);
}
?>