diff options
author | Chad Parry <github@chad.parry.org> | 2011-04-30 21:32:33 -0600 |
---|---|---|
committer | Chad Parry <github@chad.parry.org> | 2011-04-30 21:32:33 -0600 |
commit | 3a6b7438660520a725fb79a2cd360b7302aff7a9 (patch) | |
tree | 4cbe52a2fb4e720d63c7d225b9bc242c4cf6eac9 /modules/g2_import/controllers | |
parent | b875368167658fd7992812504674afeb61c64831 (diff) | |
parent | 97400b78153620262120868b37545170416413c9 (diff) |
Merge branch 'master' into rawphoto-squash
Diffstat (limited to 'modules/g2_import/controllers')
-rw-r--r-- | modules/g2_import/controllers/admin_g2_import.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/modules/g2_import/controllers/admin_g2_import.php b/modules/g2_import/controllers/admin_g2_import.php index 5c4995c9..1a705bea 100644 --- a/modules/g2_import/controllers/admin_g2_import.php +++ b/modules/g2_import/controllers/admin_g2_import.php @@ -78,12 +78,12 @@ class Admin_g2_import_Controller extends Admin_Controller { $embed_path = "$embed_path/embed.php"; } - if (g2_import::is_valid_embed_path($embed_path)) { + if (($g2_init_error = g2_import::is_valid_embed_path($embed_path)) == "ok") { message::success(t("Gallery 2 path saved")); module::set_var("g2_import", "embed_path", $embed_path); url::redirect("admin/g2_import"); } else { - $form->configure_g2_import->embed_path->add_error("invalid", 1); + $form->configure_g2_import->embed_path->add_error($g2_init_error, 1); } } @@ -120,6 +120,10 @@ class Admin_g2_import_Controller extends Admin_Controller { ->value($embed_path); $group->embed_path->error_messages( "invalid", t("The path you entered is not a Gallery 2 installation.")); + $group->embed_path->error_messages( + "broken", t("Your Gallery 2 install isn't working properly. Please verify it!")); + $group->embed_path->error_messages( + "missing", t("The path you entered does not exist.")); $group->submit("")->value($embed_path ? t("Change") : t("Continue")); return $form; } |