mirror of
https://github.com/RaspAP/raspap-webgui.git
synced 2024-11-21 23:20:22 +00:00
improve CSRFToken() implementation
This commit is contained in:
parent
2f6dc2cc05
commit
6f1ae104f3
1 changed files with 2 additions and 3 deletions
|
@ -69,9 +69,8 @@ function ensureCSRFSessionToken()
|
|||
*/
|
||||
function CSRFToken()
|
||||
{
|
||||
?>
|
||||
<input id="csrf_token" type="hidden" name="csrf_token" value="<?php echo htmlspecialchars($_SESSION['csrf_token'], ENT_QUOTES); ?>" />
|
||||
<?php
|
||||
$token = htmlspecialchars($_SESSION['csrf_token']);
|
||||
echo '<input id="csrf_token" type="hidden" name="csrf_token" value="' . $token . '">';
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue