Security fixes
This commit is contained in:
parent
89122cc4a4
commit
dc2a338847
5 changed files with 9 additions and 8 deletions
|
|
@ -24,13 +24,13 @@ else
|
|||
if ($question->get_writer() != null)
|
||||
{?><strong>Proposée par :</strong> <a href="mailto:<?php echo $question->get_writer()->getEmail(); ?>"><?php echo $question->get_writer()->getUsername(); ?></a><br><br><?php } ?>
|
||||
<strong>Cours concerné :</strong> <?php echo $question->getCourse()->getName(); ?><br><br>
|
||||
<strong>Question posée :</strong> <?php echo $question->getQuestion(); ?><br><br>
|
||||
<strong>Question posée :</strong> <?php echo nl2br(htmlentities($question->getQuestion(), ENT_COMPAT, "UTF-8")); ?><br><br>
|
||||
<strong>Réponses valides exhaustives :</strong>
|
||||
</p>
|
||||
<?php
|
||||
echo "<ul>";
|
||||
foreach($question->getAnswer() as $a)
|
||||
echo "<li>".$a."</li>";
|
||||
echo "<li>".htmlentities($a, ENT_COMPAT, "UTF-8")."</li>";
|
||||
echo "</ul>";
|
||||
?>
|
||||
<p>
|
||||
|
|
@ -64,7 +64,7 @@ foreach($cs as $c)
|
|||
|
||||
<p id="questionPart">
|
||||
<label id="q" for="question">Quelle est votre question ? </label><br>
|
||||
<textarea id="question" name="question" rows="3" cols="70"><?php echo nl2br(htmlentities(utf8_decode($question->getQuestion()))); ?></textarea>
|
||||
<textarea id="question" name="question" rows="3" cols="70"><?php echo htmlentities($question->getQuestion(), ENT_COMPAT, "UTF-8"); ?></textarea>
|
||||
</p>
|
||||
<p id="answerList">
|
||||
<label for="answer">Quelle est la réponse ?</label><br>
|
||||
|
|
|
|||
Reference in a new issue