mirror of
https://github.com/Pathduck/gallery3.git
synced 2026-08-31 03:15:46 -04:00
Refactor all calls of p::clean() to SafeString::of() and p::purify() to SafeString::purify().
Removing any p::clean() calls for arguments to t() and t2() since their args are wrapped in a SafeString anyway.
This commit is contained in:
@@ -8,10 +8,10 @@
|
||||
<ul>
|
||||
<li>
|
||||
<label for="q"><?= t("Search the gallery") ?></label>
|
||||
<input name="q" id="q" type="text" value="<?= p::clean($q) ?>"/>
|
||||
<input name="q" id="q" type="text" value="<?= SafeString::of($q)->for_html_attr() ?>"/>
|
||||
</li>
|
||||
<li>
|
||||
<input type="submit" value="<?= t("Search") ?>" />
|
||||
<input type="submit" value="<?= t("Search")->for_html_attr() ?>" />
|
||||
</li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
@@ -31,10 +31,10 @@
|
||||
<a href="<?= url::site("items/$item->id") ?>">
|
||||
<?= $item->thumb_img() ?>
|
||||
<p>
|
||||
<?= p::purify($item->title) ?>
|
||||
<?= SafeString::purify($item->title) ?>
|
||||
</p>
|
||||
<div>
|
||||
<?= nl2br(p::purify($item->description)) ?>
|
||||
<?= nl2br(SafeString::purify($item->description)) ?>
|
||||
</div>
|
||||
</a>
|
||||
</li>
|
||||
@@ -44,7 +44,7 @@
|
||||
|
||||
<? else: ?>
|
||||
<p>
|
||||
<?= t("No results found for <b>%term</b>", array("term" => p::clean($q))) ?>
|
||||
<?= t("No results found for <b>%term</b>", array("term" => $q)) ?>
|
||||
</p>
|
||||
|
||||
<? endif; ?>
|
||||
|
||||
Reference in New Issue
Block a user