templates: avoid echo, fix potential XSS
This commit is contained in:
parent
8d05f77e9c
commit
f9f768da5f
|
|
@ -8,9 +8,9 @@ if ( \OCP\Util::getVersion()[0] >= 12 )
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<?php if ( !empty($_['errormsgs']) ) {?>
|
<?php if ( !empty($_['errormsgs']) ) {?>
|
||||||
<ul class="error">
|
<ul class="error">
|
||||||
<?php foreach ( $_['errormsgs'] as $errormsg ) {
|
<?php foreach ( $_['errormsgs'] as $errormsg ) { ?>
|
||||||
echo "<li>$errormsg</li>";
|
<li><?php p($errormsg); ?></li>
|
||||||
} ?>
|
<?php } ?>
|
||||||
</ul>
|
</ul>
|
||||||
<?php } else { ?>
|
<?php } else { ?>
|
||||||
<ul class="msg">
|
<ul class="msg">
|
||||||
|
|
@ -18,13 +18,13 @@ if ( \OCP\Util::getVersion()[0] >= 12 )
|
||||||
</ul>
|
</ul>
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
<p class="grouptop">
|
<p class="grouptop">
|
||||||
<input type="email" name="email" id="email" value="<?php echo $_['email']; ?>" disabled />
|
<input type="email" name="email" id="email" value="<?php p($_['email']); ?>" disabled />
|
||||||
<label for="email" class="infield"><?php echo $_['email']; ?></label>
|
<label for="email" class="infield"><?php p($_['email']); ?></label>
|
||||||
<img id="email-icon" class="svg" src="<?php print_unescaped(image_path('', 'actions/mail.svg')); ?>" alt=""/>
|
<img id="email-icon" class="svg" src="<?php print_unescaped(image_path('', 'actions/mail.svg')); ?>" alt=""/>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p class="groupmiddle">
|
<p class="groupmiddle">
|
||||||
<input type="text" name="username" id="username" value="<?php echo !empty($_['entered_data']['user']) ? $_['entered_data']['user'] : ''; ?>" placeholder="<?php p($l->t('Username')); ?>" />
|
<input type="text" name="username" id="username" value="<?php if (!empty($_['entered_data']['user'])) { p($_['entered_data']['user']); } ?>" placeholder="<?php p($l->t('Username')); ?>" />
|
||||||
<label for="username" class="infield"><?php p($l->t('Username')); ?></label>
|
<label for="username" class="infield"><?php p($l->t('Username')); ?></label>
|
||||||
<img id="username-icon" class="svg" src="<?php print_unescaped(image_path('', 'actions/user.svg')); ?>" alt=""/>
|
<img id="username-icon" class="svg" src="<?php print_unescaped(image_path('', 'actions/user.svg')); ?>" alt=""/>
|
||||||
</p>
|
</p>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue