2013-10-13 08:01:01 +00:00
|
|
|
<?
|
|
|
|
include(SERVER_ROOT.'/classes/text.class.php');
|
|
|
|
$Text = new TEXT(true);
|
|
|
|
if (!check_perms("users_mod")) {
|
|
|
|
error(403);
|
|
|
|
}
|
|
|
|
|
|
|
|
$ID = $_GET['id'];
|
|
|
|
|
|
|
|
if (!is_number($ID)) {
|
|
|
|
error(404);
|
|
|
|
}
|
|
|
|
|
2013-10-14 08:00:53 +00:00
|
|
|
$DB->query("
|
|
|
|
SELECT ID, Question, UserID, Date
|
|
|
|
FROM user_questions
|
|
|
|
WHERE ID = '$ID'");
|
2013-10-13 08:01:01 +00:00
|
|
|
$Question = $DB->next_record();
|
|
|
|
|
|
|
|
View::show_header("Ask the Staff");
|
|
|
|
?>
|
|
|
|
|
|
|
|
<div class="thin">
|
|
|
|
<h2>
|
|
|
|
Answer Question
|
|
|
|
</h2>
|
|
|
|
<div class="linkbox">
|
|
|
|
<a class="brackets" href="questions.php">View questions</a>
|
|
|
|
<a class="brackets" href="questions.php?action=answers">View staff answers</a>
|
2013-10-14 08:00:53 +00:00
|
|
|
<a class="brackets" href="questions.php?action=popular_questions">Popular questions</a>
|
2013-10-13 08:01:01 +00:00
|
|
|
<div class="box box2">
|
|
|
|
<div class="head">
|
|
|
|
<span>
|
|
|
|
#<?=$Question['ID']?>
|
|
|
|
<?=Users::format_username($Question['UserID'])?> - <?=time_diff($Question['Date'])?>
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
<div class="pad">
|
|
|
|
<?=$Text->full_format($Question['Question'])?>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="center box pad">
|
2013-10-14 08:00:53 +00:00
|
|
|
<form method="post">
|
2013-10-13 08:01:01 +00:00
|
|
|
<input type="hidden" name="action" value="take_answer_question" />
|
|
|
|
<input type="hidden" name="auth" value="<?=$LoggedUser['AuthKey']?>" />
|
|
|
|
<input type="hidden" name="id" value="<?=$ID?>" />
|
|
|
|
<textarea id="answer" class="required" onkeyup="resize('answer');" name="answer" cols="90" rows="8"></textarea>
|
|
|
|
<div id="buttons" class="center">
|
|
|
|
<input type="submit" class="submit" id="submit_button" value="Answer" />
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<?
|
2013-10-14 08:00:53 +00:00
|
|
|
View::show_footer();
|