diff options
Diffstat (limited to 'modules/gallery/views')
| -rw-r--r-- | modules/gallery/views/admin_languages.html.php | 3 | ||||
| -rw-r--r-- | modules/gallery/views/admin_maintenance.html.php | 32 | ||||
| -rw-r--r-- | modules/gallery/views/admin_maintenance_show_log.html.php | 2 | ||||
| -rw-r--r-- | modules/gallery/views/form_uploadify.html.php | 4 | ||||
| -rw-r--r-- | modules/gallery/views/kohana/error.php | 22 | ||||
| -rw-r--r-- | modules/gallery/views/login_ajax.html.php | 2 | ||||
| -rw-r--r-- | modules/gallery/views/maintenance.html.php | 50 | ||||
| -rw-r--r-- | modules/gallery/views/move_browse.html.php | 13 | ||||
| -rw-r--r-- | modules/gallery/views/quick_delete_confirm.html.php | 12 | ||||
| -rw-r--r-- | modules/gallery/views/upgrader.html.php | 8 | ||||
| -rw-r--r-- | modules/gallery/views/welcome_message.html.php | 2 |
11 files changed, 70 insertions, 80 deletions
diff --git a/modules/gallery/views/admin_languages.html.php b/modules/gallery/views/admin_languages.html.php index d4b7b0c1..01d1ce3f 100644 --- a/modules/gallery/views/admin_languages.html.php +++ b/modules/gallery/views/admin_languages.html.php @@ -107,6 +107,9 @@ </a> <h3><?= t("Sharing your translations") ?></h3> + <p> + <?= t("Sharing your own translations with the Gallery community is easy. Please do!") ?> + </p> <?= $share_translations_form ?> </div> </div> diff --git a/modules/gallery/views/admin_maintenance.html.php b/modules/gallery/views/admin_maintenance.html.php index ac597715..4bfc57f0 100644 --- a/modules/gallery/views/admin_maintenance.html.php +++ b/modules/gallery/views/admin_maintenance.html.php @@ -1,13 +1,29 @@ <?php defined("SYSPATH") or die("No direct script access.") ?> <div id="g-admin-maintenance" class="g-block"> - <h1> <?= t("Maintenance tasks") ?> </h1> - <p> - <?= t("Occasionally your Gallery will require some maintenance. Here are some tasks you can use to keep it running smoothly.") ?> - </p> + <h1> <?= t("Maintenance") ?> </h1> + <div class="g-block-content"> + <div id="g-maintenance-mode"> + <?= t("When you're performing maintenance on your Gallery, you can enable <b>maintenance mode</b> which prevents any non-admin from accessing your Gallery. Some of the tasks below will automatically put your Gallery in maintenance mode for you.") ?> + <ul id="g-action-status" class="g-message-block"> + <? if (module::get_var("gallery", "maintenance_mode")): ?> + <li class="g-warning"> + <?= t("Maintenance mode is <b>on</b>. Non admins cannot access your Gallery. <a href=\"%enable_maintenance_mode_url\">Turn off maintenance mode</a>", array("enable_maintenance_mode_url" => url::site("admin/maintenance/maintenance_mode/0?csrf=$csrf"))) ?> + </li> + <? else: ?> + <li class="g-info"> + <?= t("Maintenance mode is off. User access is permitted. <a href=\"%enable_maintenance_mode_url\">Turn on maintenance mode</a>", array("enable_maintenance_mode_url" => url::site("admin/maintenance/maintenance_mode/1?csrf=$csrf"))) ?> + </li> + <? endif ?> + </ul> + </div> + </div> <div class="g-block-content"> <div id="g-available-tasks"> - <h2> <?= t("Available tasks") ?> </h2> + <h2> <?= t("Maintenance tasks") ?> </h2> + <p> + <?= t("Occasionally your Gallery will require some maintenance. Here are some tasks you can use to keep it running smoothly.") ?> + </p> <table> <tr> <th> @@ -41,6 +57,9 @@ <? if ($running_tasks->count()): ?> <div id="g-running-tasks"> + <a href="<?= url::site("admin/maintenance/cancel_running_tasks?csrf=$csrf") ?>" + class="g-button g-right ui-icon-left ui-state-default ui-corner-all"> + <?= t("cancel all running") ?></a> <h2> <?= t("Running tasks") ?> </h2> <table> <tr> @@ -60,9 +79,6 @@ <?= t("Owner") ?> </th> <th> - <a href="<?= url::site("admin/maintenance/cancel_running_tasks?csrf=$csrf") ?>" - class="g-button g-right ui-icon-left ui-state-default ui-corner-all"> - <?= t("cancel all") ?></a> <?= t("Action") ?> </th> </tr> diff --git a/modules/gallery/views/admin_maintenance_show_log.html.php b/modules/gallery/views/admin_maintenance_show_log.html.php index d2472fdc..ecf882f0 100644 --- a/modules/gallery/views/admin_maintenance_show_log.html.php +++ b/modules/gallery/views/admin_maintenance_show_log.html.php @@ -15,5 +15,5 @@ appendTo('body').submit().remove(); <pre><?= html::purify($task->get_log()) ?></pre> </div> <button id="g-close" class="ui-state-default ui-corner-all" onclick="dismiss()"><?= t("Close") ?></button> - <button id="g-save" class="ui-state-default ui-corner-all" onclick="download()"><?= t("Save") ?></button> + <button id="g-save" class="ui-state-default ui-corner-all" onclick="download()"><?= t("Download") ?></button> </div> diff --git a/modules/gallery/views/form_uploadify.html.php b/modules/gallery/views/form_uploadify.html.php index 588fa16d..4f564b07 100644 --- a/modules/gallery/views/form_uploadify.html.php +++ b/modules/gallery/views/form_uploadify.html.php @@ -7,9 +7,9 @@ width: 150, height: 33, uploader: "<?= url::file("lib/uploadify/uploadify.swf") ?>", - script: "<?= url::site("flash_uploader/add_photo/{$album->id}") ?>", + script: "<?= url::site("uploader/add_photo/{$album->id}") ?>", scriptData: <?= json_encode($script_data) ?>, - fileExt: "*.gif;*.jpg;*.jpeg;*.png;*.flv;*.mp4;*.GIF;*.JPG;*.JPEG;*.PNG;*.FLV;*.MP4", + fileExt: "*.gif;*.jpg;*.jpeg;*.png;*.flv;*.mp4;*.m4v;*.GIF;*.JPG;*.JPEG;*.PNG;*.FLV;*.MP4;*.M4V", fileDesc: <?= t("Photos and movies")->for_js() ?>, cancelImg: "<?= url::file("lib/uploadify/cancel.png") ?>", simUploadLimit: <?= $simultaneous_upload_limit ?>, diff --git a/modules/gallery/views/kohana/error.php b/modules/gallery/views/kohana/error.php index cc9d2e84..0e84f093 100644 --- a/modules/gallery/views/kohana/error.php +++ b/modules/gallery/views/kohana/error.php @@ -25,16 +25,20 @@ try { // Try to show a themed error page for 404 errors if ($e instanceof Kohana_404_Exception) { - $view = new Theme_View("page.html", "other", "error"); - $view->page_title = t("Dang... Page not found!"); - $view->content = new View("error_404.html"); - $user = identity::active_user(); - $view->content->is_guest = $user && $user->guest; - if ($view->content->is_guest) { - $view->content->login_form = new View("login_ajax.html"); - $view->content->login_form->form = auth::get_login_form("login/auth_html"); + if (Router::$controller == "file_proxy") { + print "File not found"; + } else { + $view = new Theme_View("page.html", "other", "error"); + $view->page_title = t("Dang... Page not found!"); + $view->content = new View("error_404.html"); + $user = identity::active_user(); + $view->content->is_guest = $user && $user->guest; + if ($view->content->is_guest) { + $view->content->login_form = new View("login_ajax.html"); + $view->content->login_form->form = auth::get_login_form("login/auth_html"); + } + print $view; } - print $view; return; } diff --git a/modules/gallery/views/login_ajax.html.php b/modules/gallery/views/login_ajax.html.php index 88fe2389..a40d1950 100644 --- a/modules/gallery/views/login_ajax.html.php +++ b/modules/gallery/views/login_ajax.html.php @@ -43,7 +43,7 @@ <li id="g-login-form"> <?= $form ?> </li> - <? if (identity::is_writable()): ?> + <? if (identity::is_writable() && !module::get_var("gallery", "maintenance_mode")): ?> <li> <a href="#" id="g-password-reset" class="g-right g-text-small"><?= t("Forgot your password?") ?></a> </li> diff --git a/modules/gallery/views/maintenance.html.php b/modules/gallery/views/maintenance.html.php deleted file mode 100644 index 6351b6ab..00000000 --- a/modules/gallery/views/maintenance.html.php +++ /dev/null @@ -1,50 +0,0 @@ -<?php defined("SYSPATH") or die("No direct script access.") ?> -<html> - <head> - <title> - <?= t("Gallery - maintenance mode") ?> - </title> - <style> - body { - background: #ccc; - } - form { - border: 1px solid #555; - background: #999; - width: 300px; - } - fieldset { - border: none; - } - fieldset legend { - font-size: 24px; - display: none !important; - padding-left: 0px; - } - ul { - list-style-type: none; - margin-top: 0px; - padding-left: 0px; - bullet-style: none; - } - ul li { - margin-left: 0px; - } - label { - width: 60px; - display: block; - } - </style> - </head> - <body> - <h1> - <?= t("Gallery - maintenance mode") ?> - </h1> - <p> - <?= t("This site is currently only accessible by site administrators.") ?> - </p> - <?= auth::get_login_form("login/auth_html") ?> - </body> -</html> - - diff --git a/modules/gallery/views/move_browse.html.php b/modules/gallery/views/move_browse.html.php index ce3fc2fd..f77c724c 100644 --- a/modules/gallery/views/move_browse.html.php +++ b/modules/gallery/views/move_browse.html.php @@ -1,4 +1,5 @@ <?php defined("SYSPATH") or die("No direct script access.") ?> +<div> <script type="text/javascript"> var load_tree = function(target_id, locked) { var load_url = "<?= url::site("move/show_sub_tree/{$source->id}/__TARGETID__") ?>"; @@ -24,13 +25,13 @@ } } </script> -<h1 style="display: none"> +<h1 style="display:none" > <? if ($source->type == "photo"): ?> - <? t("Move this photo to a new album") ?> + <?= t("Move this photo to a new album") ?> <? elseif ($source->type == "movie"): ?> - <? t("Move this movie to a new album") ?> + <?= t("Move this movie to a new album") ?> <? elseif ($source->type == "album"): ?> - <? t("Move this album to a new album") ?> + <?= t("Move this album to a new album") ?> <? endif ?> </h1> <div id="g-move"> @@ -42,6 +43,8 @@ <form method="post" action="<?= url::site("move/save/$source->id") ?>"> <?= access::csrf_form_field() ?> <input type="hidden" name="target_id" value="" /> - <input type="submit" id="g-move-button" value="<?= t("Move")->for_html_attr() ?>" disabled="disabled"/> + <input type="submit" id="g-move-button" value="<?= t("Move")->for_html_attr() ?>" + disabled="disabled" class="submit" /> </form> </div> +</div> diff --git a/modules/gallery/views/quick_delete_confirm.html.php b/modules/gallery/views/quick_delete_confirm.html.php new file mode 100644 index 00000000..176ffb96 --- /dev/null +++ b/modules/gallery/views/quick_delete_confirm.html.php @@ -0,0 +1,12 @@ +<?php defined("SYSPATH") or die("No direct script access.") ?> +<div class="ui-helper-clearfix"> + <p> + <? if ($item->is_album()): ?> + <?= t("Delete the album <b>%title</b>? All photos and movies in the album will also be deleted.", + array("title" => html::purify($item->title))) ?> + <? else: ?> + <?= t("Are you sure you want to delete <b>%title</b>?", array("title" => html::purify($item->title))) ?> + <? endif ?> + </p> + <?= $form ?> +</div> diff --git a/modules/gallery/views/upgrader.html.php b/modules/gallery/views/upgrader.html.php index c7a96cb5..0ce24ef8 100644 --- a/modules/gallery/views/upgrader.html.php +++ b/modules/gallery/views/upgrader.html.php @@ -1,4 +1,6 @@ <?php defined("SYSPATH") or die("No direct script access.") ?> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" + "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <title><?= t("Gallery 3 upgrader") ?></title> @@ -107,7 +109,7 @@ </li> <? endif ?> <? endforeach ?> - </p> + </ul> <? endif ?> <? else: // can_upgrade ?> <h1> <?= t("Who are you?") ?> </h1> @@ -121,11 +123,11 @@ </div> <div id="footer"> <p> - <i> + <em> <?= t("Did something go wrong? Try the <a href=\"%faq_url\">FAQ</a> or ask in the <a href=\"%forums_url\">Gallery forums</a>.", array("faq_url" => "http://codex.gallery2.org/Gallery3:FAQ", "forums_url" => "http://gallery.menalto.com/forum")) ?> - </i> + </em> </p> </div> </div> diff --git a/modules/gallery/views/welcome_message.html.php b/modules/gallery/views/welcome_message.html.php index 4d6ed726..1fcca971 100644 --- a/modules/gallery/views/welcome_message.html.php +++ b/modules/gallery/views/welcome_message.html.php @@ -18,7 +18,7 @@ <a href="<?= url::site("admin/users/edit_user_form/{$user->id}") ?>" title="<?= t("Edit your profile")->for_html_attr() ?>" id="g-after-install-change-password-link" - class="g-button ui-state-default ui-corners-all"> + class="g-button ui-state-default ui-corner-all"> <?= t("Change password and email now") ?> </a> <script type="text/javascript"> |
