summaryrefslogtreecommitdiff
path: root/modules/gallery/helpers
diff options
context:
space:
mode:
Diffstat (limited to 'modules/gallery/helpers')
-rw-r--r--modules/gallery/helpers/MY_html.php4
-rw-r--r--modules/gallery/helpers/gallery_rss.php4
-rw-r--r--modules/gallery/helpers/gallery_task.php4
3 files changed, 6 insertions, 6 deletions
diff --git a/modules/gallery/helpers/MY_html.php b/modules/gallery/helpers/MY_html.php
index eb388811..75114898 100644
--- a/modules/gallery/helpers/MY_html.php
+++ b/modules/gallery/helpers/MY_html.php
@@ -65,11 +65,11 @@ class html extends html_Core {
*
* Example:<pre>
* <script type="text/javascript>"
- * var some_js_var = "<?= html::escape_for_js($php_var) ?>";
+ * var some_js_var = "<?= html::clean_js($php_var) ?>";
* </script>
* </pre>
*/
- static function escape_for_js($string) {
+ static function clean_js($string) {
return SafeString::of($string)->for_js();
}
diff --git a/modules/gallery/helpers/gallery_rss.php b/modules/gallery/helpers/gallery_rss.php
index affb3101..dee6ae40 100644
--- a/modules/gallery/helpers/gallery_rss.php
+++ b/modules/gallery/helpers/gallery_rss.php
@@ -53,9 +53,9 @@ class gallery_rss_Core {
->descendants($limit, $offset, array("type" => "photo"));
$feed->max_pages = ceil(
$item->viewable()->descendants_count(array("type" => "photo")) / $limit);
- $feed->title = SafeString::purify($item->title);
+ $feed->title = html::purify($item->title);
$feed->link = url::abs_site("albums/{$item->id}");
- $feed->description = nl2br(SafeString::purify($item->description));
+ $feed->description = nl2br(html::purify($item->description));
return $feed;
}
diff --git a/modules/gallery/helpers/gallery_task.php b/modules/gallery/helpers/gallery_task.php
index 8c0e8aa8..c9557324 100644
--- a/modules/gallery/helpers/gallery_task.php
+++ b/modules/gallery/helpers/gallery_task.php
@@ -64,10 +64,10 @@ class gallery_task_Core {
if (!$success) {
$ignored[$item->id] = 1;
$errors[] = t("Unable to rebuild images for '%title'",
- array("title" => SafeString::purify($item->title)));
+ array("title" => html::purify($item->title)));
} else {
$errors[] = t("Successfully rebuilt images for '%title'",
- array("title" => SafeString::purify($item->title)));
+ array("title" => html::purify($item->title)));
}
}