query("SELECT * FROM users WHERE username = '" . $_GET["q"] . "';")->fetchArray(SQLITE3_ASSOC); if(!$p_user || !$p_user["id"]){ include("404.php"); die(); } if(isset($_SESSION["uid"])){ if($_SESSION["uid"] == $p_user["id"]){ $is_current_user = true; } } ?> <?= $p_user["username"] ?> | LibreCat

"); if($fancy_urls){ echo("config"); echo(" - "); echo('share on twitter'); } else{ echo("config"); } } ?>

"/>

name="anon"/> Post anonymously

$errorMsg

\n"; ?>
prepare("SELECT * FROM users WHERE id = :id"); $qs = $db->query("SELECT * FROM questions WHERE user = '" . $p_user["id"] . "' ORDER BY id DESC LIMIT 0, 10;"); $time = new DateTime("@0"); while($current = $qs->fetchArray(SQLITE3_ASSOC)){ // Execute prepared statement $u_prep->bindValue(":id", $current["by"], SQLITE3_INTEGER); $q_user = $u_prep->execute()->fetchArray(SQLITE3_ASSOC); echo("
"); if($q_user["id"] == 0) echo("

" . $q_user["name"] ."

"); else if($fancy_urls) echo("

" . $q_user["name"] ."

\n"); else echo("

" . $q_user["name"] ."

\n"); echo("\t

". $current["question"] ."

\n"); if($is_current_user){ echo("\treply "); echo("\tdelete "); echo("fav ignore "); } // Time $time->settimestamp($current["q_date"]); echo(''); echo("

" . $time->format("Y-m-d h:i:s") . "

"); echo("
"); if($current["answer"]){ echo("
"); echo("

" . $current["answer"] . "

"); $time->settimestamp($current["a_date"]); echo("

" . $time->format("Y-m-d h:i:s") . "

"); echo("
"); } echo("\n\n"); echo("
"); } ?>