summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/gallery/views/admin_languages.html.php21
-rw-r--r--modules/organize/views/organize_dialog.html.php2
-rw-r--r--modules/organize/views/organize_tree.html.php6
3 files changed, 17 insertions, 12 deletions
diff --git a/modules/gallery/views/admin_languages.html.php b/modules/gallery/views/admin_languages.html.php
index 4025437a..4bee9bb1 100644
--- a/modules/gallery/views/admin_languages.html.php
+++ b/modules/gallery/views/admin_languages.html.php
@@ -36,11 +36,11 @@
<? endforeach ?>
</table>
- <input type="submit" value="<?= t("Update languages") ?>" />
+ <input type="submit" value="<?= t("Update languages")->for_html_attr() ?>" />
</form>
<script type="text/javascript">
- var old_default_locale = "<?= $default_locale ?>";
+ var old_default_locale = "<?= SafeString::of($default_locale)->for_js() ?>";
$("input[name='installed_locales[]']").change(function (event) {
if (this.checked) {
@@ -57,7 +57,7 @@
dataType: "json",
success: function(data) {
if (data.result == "success") {
- el = $('<a href="<?= url::site("admin/maintenance/start/gallery_task::update_l10n?csrf=$csrf") ?>"></a>'); // this is a little hack to trigger the update_l10n task in a dialog
+ el = $('<a href="<?= url::site("admin/maintenance/start/gallery_task::update_l10n?csrf=$csrf")->for_js() ?>"></a>'); // this is a little hack to trigger the update_l10n task in a dialog
el.gallery_dialog();
el.trigger('click');
}
@@ -77,20 +77,25 @@
<div class="gBlock">
<a href="http://codex.gallery2.org/Gallery3:Localization" target="_blank"
class="gDocLink ui-state-default ui-corner-all ui-icon ui-icon-help"
- title="<?= t("Localization documentation") ?>">
+ title="<?= t("Localization documentation")->for_html_attr() ?>">
<?= t("Localization documentation") ?>
</a>
- <p><strong><?= t("Step 1") ?>:</strong> <?= t("Make sure the target language is installed and updated (check above).") ?></p>
+ <p><?= t("<strong>Step 1:</strong> Make sure the target language is installed and up to date (check above).") ?></p>
- <p><strong><?= t("Step 2") ?>:</strong> <?= t("Make sure the target language is the active one (currently '").locales::display_name()."')." ?></p>
+ <p><?= t("<strong>Step 2:</strong> Make sure you have selected the right target language (currently %default_locale).",
+ array("default_locale" => locales::display_name())) ?></p>
- <p><strong><?= t("Step 3") ?>:</strong> <?= t("Start the translation mode and the translation interface will appear at the bottom of each Gallery page.") ?></p>
+ <p><?= t("<strong>Step 3:</strong> Start the translation mode and the translation interface will appear at the bottom of each Gallery page.") ?></p>
<a href="<?= url::site("l10n_client/toggle_l10n_mode?csrf=".access::csrf_token()) ?>"
class="gButtonLink ui-state-default ui-corner-all ui-icon-left">
<span class="ui-icon ui-icon-power"></span>
- <?= t((Session::instance()->get("l10n_mode", false)) ? "Stop translation mode" : "Start translation mode") ?>
+ <? if (Session::instance()->get("l10n_mode", false)): ?>
+ <?= t("Stop translation mode") ?>
+ <? else: ?>
+ <?= t("Start translation mode") ?>
+ <? endif ?>
</a>
</div>
diff --git a/modules/organize/views/organize_dialog.html.php b/modules/organize/views/organize_dialog.html.php
index b03c066c..27d5b508 100644
--- a/modules/organize/views/organize_dialog.html.php
+++ b/modules/organize/views/organize_dialog.html.php
@@ -5,7 +5,7 @@
var sort_order_url = "<?= url::site("organize/sort_order/__ALBUM_ID__/__COL__/__DIR__?csrf=$csrf") ?>";
</script>
<div id="gOrganize" class="gDialogPanel">
- <h1 style="display:none"><?= t("Organize %name", array("name" => p::purify($album->title))) ?></h1>
+ <h1 style="display:none"><?= t("Organize %name", array("name" => SafeString::purify($album->title))) ?></h1>
<div id="bd">
<div class="yui-gf">
<div class="yui-u first">
diff --git a/modules/organize/views/organize_tree.html.php b/modules/organize/views/organize_tree.html.php
index 36f900ac..387d5977 100644
--- a/modules/organize/views/organize_tree.html.php
+++ b/modules/organize/views/organize_tree.html.php
@@ -5,7 +5,7 @@
<span class="ui-icon ui-icon-minus">
</span>
<span class="gAlbumText" ref="<?= $parent->id ?>">
- <?= p::clean($parent->title) ?>
+ <?= SafeString::of($parent->title) ?>
</span>
<ul class="ui-icon-plus">
<? endforeach ?>
@@ -17,7 +17,7 @@
</span>
<span class="gAlbumText <?= $peer->id == $album->id ? "selected" : "" ?>"
ref="<?= $peer->id ?>">
- <?= p::clean($peer->title) ?>
+ <?= SafeString::of($peer->title) ?>
</span>
<? if ($peer->id == $album->id): ?>
@@ -29,7 +29,7 @@
</span>
<span class="gAlbumText"
ref="<?= $child->id ?>">
- <?= p::clean($child->title) ?>
+ <?= SafeString::of($child->title) ?>
</span>
</li>
<? endforeach ?>