diff options
Diffstat (limited to 'modules/gallery/tests')
-rw-r--r-- | modules/gallery/tests/Access_Helper_Test.php | 153 | ||||
-rw-r--r-- | modules/gallery/tests/Albums_Controller_Test.php | 15 | ||||
-rw-r--r-- | modules/gallery/tests/Controller_Auth_Test.php | 13 | ||||
-rw-r--r-- | modules/gallery/tests/Database_Test.php | 22 | ||||
-rw-r--r-- | modules/gallery/tests/DrawForm_Test.php | 12 | ||||
-rw-r--r-- | modules/gallery/tests/File_Structure_Test.php | 36 | ||||
-rw-r--r-- | modules/gallery/tests/Gallery_Filters.php | 48 | ||||
-rw-r--r-- | modules/gallery/tests/Item_Helper_Test.php | 6 | ||||
-rw-r--r-- | modules/gallery/tests/Item_Model_Test.php | 136 | ||||
-rw-r--r-- | modules/gallery/tests/Photos_Controller_Test.php | 14 | ||||
-rw-r--r-- | modules/gallery/tests/Xss_Security_Test.php | 4 | ||||
-rw-r--r-- | modules/gallery/tests/controller_auth_data.txt | 10 | ||||
-rw-r--r-- | modules/gallery/tests/selenium/Add_Comment.html | 8 | ||||
-rw-r--r-- | modules/gallery/tests/selenium/Login.html | 8 | ||||
-rw-r--r-- | modules/gallery/tests/xss_data.txt | 421 |
15 files changed, 547 insertions, 359 deletions
diff --git a/modules/gallery/tests/Access_Helper_Test.php b/modules/gallery/tests/Access_Helper_Test.php index 59cec453..e9e5cb26 100644 --- a/modules/gallery/tests/Access_Helper_Test.php +++ b/modules/gallery/tests/Access_Helper_Test.php @@ -22,8 +22,8 @@ class Access_Helper_Test extends Unit_Test_Case { public function teardown() { try { - $group = ORM::factory("group")->where("name", "access_test")->find(); - if ($group->loaded) { + $group = identity::lookup_group_by_name("access_test"); + if (!empty($group)) { $group->delete(); } } catch (Exception $e) { } @@ -33,24 +33,24 @@ class Access_Helper_Test extends Unit_Test_Case { } catch (Exception $e) { } try { - $user = ORM::factory("user")->where("name", "access_test")->find(); - if ($user->loaded) { + $user = identity::lookup_user_by_name("access_test"); + if (!empty($user)) { $user->delete(); } } catch (Exception $e) { } // Reset some permissions that we mangle below $root = ORM::factory("item", 1); - access::allow(group::everybody(), "view", $root); + access::allow(identity::everybody(), "view", $root); } public function setup() { - user::set_active(user::guest()); + identity::set_active_user(identity::guest()); } public function groups_and_permissions_are_bound_to_columns_test() { access::register_permission("access_test", "Access Test"); - $group = group::create("access_test"); + $group = identity::create_group("access_test"); // We have a new column for this perm / group combo $fields = Database::instance()->list_fields("access_caches"); @@ -65,17 +65,17 @@ class Access_Helper_Test extends Unit_Test_Case { } public function user_can_access_test() { - $access_test = group::create("access_test"); + $access_test = identity::create_group("access_test"); $root = ORM::factory("item", 1); access::allow($access_test, "view", $root); $item = album::create($root, rand(), "test album"); - access::deny(group::everybody(), "view", $item); - access::deny(group::registered_users(), "view", $item); + access::deny(identity::everybody(), "view", $item); + access::deny(identity::registered_users(), "view", $item); - $user = user::create("access_test", "Access Test", ""); + $user = identity::create_user("access_test", "Access Test", ""); foreach ($user->groups as $group) { $user->remove($group); } @@ -89,10 +89,10 @@ class Access_Helper_Test extends Unit_Test_Case { $root = ORM::factory("item", 1); $item = album::create($root, rand(), "test album"); - access::deny(group::everybody(), "view", $item); - access::deny(group::registered_users(), "view", $item); + access::deny(identity::everybody(), "view", $item); + access::deny(identity::registered_users(), "view", $item); - $user = user::create("access_test", "Access Test", ""); + $user = identity::create_user("access_test", "Access Test", ""); foreach ($user->groups as $group) { $user->remove($group); } @@ -121,14 +121,11 @@ class Access_Helper_Test extends Unit_Test_Case { $root = ORM::factory("item", 1); $album = album::create($root, rand(), "test album"); - access::allow(group::everybody(), "view", $album); + access::allow(identity::everybody(), "view", $album); - $photo = ORM::factory("item"); - $photo->type = "photo"; - $photo->add_to_parent($album); - access::add_item($photo); + $photo = photo::create($album, MODPATH . "gallery/images/gallery.png", "", ""); - $this->assert_true($photo->__get("view_" . group::everybody()->id)); + $this->assert_true($photo->__get("view_" . identity::everybody()->id)); } public function can_allow_deny_and_reset_intent_test() { @@ -137,23 +134,23 @@ class Access_Helper_Test extends Unit_Test_Case { $intent = ORM::factory("access_intent")->where("item_id", $album)->find(); // Allow - access::allow(group::everybody(), "view", $album); + access::allow(identity::everybody(), "view", $album); $this->assert_same(access::ALLOW, $intent->reload()->view_1); // Deny - access::deny(group::everybody(), "view", $album); + access::deny(identity::everybody(), "view", $album); $this->assert_same( access::DENY, ORM::factory("access_intent")->where("item_id", $album)->find()->view_1); // Allow again. If the initial value was allow, then the first Allow clause above may not // have actually changed any values. - access::allow(group::everybody(), "view", $album); + access::allow(identity::everybody(), "view", $album); $this->assert_same( access::ALLOW, ORM::factory("access_intent")->where("item_id", $album)->find()->view_1); - access::reset(group::everybody(), "view", $album); + access::reset(identity::everybody(), "view", $album); $this->assert_same( null, ORM::factory("access_intent")->where("item_id", $album)->find()->view_1); @@ -161,7 +158,7 @@ class Access_Helper_Test extends Unit_Test_Case { public function cant_reset_root_item_test() { try { - access::reset(group::everybody(), "view", ORM::factory("item", 1)); + access::reset(identity::everybody(), "view", ORM::factory("item", 1)); } catch (Exception $e) { return; } @@ -170,17 +167,17 @@ class Access_Helper_Test extends Unit_Test_Case { public function can_view_item_test() { $root = ORM::factory("item", 1); - access::allow(group::everybody(), "view", $root); - $this->assert_true(access::group_can(group::everybody(), "view", $root)); + access::allow(identity::everybody(), "view", $root); + $this->assert_true(access::group_can(identity::everybody(), "view", $root)); } public function can_always_fails_on_unloaded_items_test() { $root = ORM::factory("item", 1); - access::allow(group::everybody(), "view", $root); - $this->assert_true(access::group_can(group::everybody(), "view", $root)); + access::allow(identity::everybody(), "view", $root); + $this->assert_true(access::group_can(identity::everybody(), "view", $root)); $bogus = ORM::factory("item", -1); - $this->assert_false(access::group_can(group::everybody(), "view", $bogus)); + $this->assert_false(access::group_can(identity::everybody(), "view", $bogus)); } public function cant_view_child_of_hidden_parent_test() { @@ -188,21 +185,21 @@ class Access_Helper_Test extends Unit_Test_Case { $album = album::create($root, rand(), "test album"); $root->reload(); - access::deny(group::everybody(), "view", $root); - access::reset(group::everybody(), "view", $album); + access::deny(identity::everybody(), "view", $root); + access::reset(identity::everybody(), "view", $album); $album->reload(); - $this->assert_false(access::group_can(group::everybody(), "view", $album)); + $this->assert_false(access::group_can(identity::everybody(), "view", $album)); } public function view_permissions_propagate_down_test() { $root = ORM::factory("item", 1); $album = album::create($root, rand(), "test album"); - access::allow(group::everybody(), "view", $root); - access::reset(group::everybody(), "view", $album); + access::allow(identity::everybody(), "view", $root); + access::reset(identity::everybody(), "view", $album); $album->reload(); - $this->assert_true(access::group_can(group::everybody(), "view", $album)); + $this->assert_true(access::group_can(identity::everybody(), "view", $album)); } public function can_toggle_view_permissions_propagate_down_test() { @@ -217,18 +214,18 @@ class Access_Helper_Test extends Unit_Test_Case { $album3->reload(); $album4->reload(); - access::allow(group::everybody(), "view", $root); - access::deny(group::everybody(), "view", $album1); - access::reset(group::everybody(), "view", $album2); - access::reset(group::everybody(), "view", $album3); - access::reset(group::everybody(), "view", $album4); + access::allow(identity::everybody(), "view", $root); + access::deny(identity::everybody(), "view", $album1); + access::reset(identity::everybody(), "view", $album2); + access::reset(identity::everybody(), "view", $album3); + access::reset(identity::everybody(), "view", $album4); $album4->reload(); - $this->assert_false(access::group_can(group::everybody(), "view", $album4)); + $this->assert_false(access::group_can(identity::everybody(), "view", $album4)); - access::allow(group::everybody(), "view", $album1); + access::allow(identity::everybody(), "view", $album1); $album4->reload(); - $this->assert_true(access::group_can(group::everybody(), "view", $album4)); + $this->assert_true(access::group_can(identity::everybody(), "view", $album4)); } public function revoked_view_permissions_cant_be_allowed_lower_down_test() { @@ -237,29 +234,29 @@ class Access_Helper_Test extends Unit_Test_Case { $album2 = album::create($album1, rand(), "test album"); $root->reload(); - access::deny(group::everybody(), "view", $root); - access::allow(group::everybody(), "view", $album2); + access::deny(identity::everybody(), "view", $root); + access::allow(identity::everybody(), "view", $album2); $album1->reload(); - $this->assert_false(access::group_can(group::everybody(), "view", $album1)); + $this->assert_false(access::group_can(identity::everybody(), "view", $album1)); $album2->reload(); - $this->assert_false(access::group_can(group::everybody(), "view", $album2)); + $this->assert_false(access::group_can(identity::everybody(), "view", $album2)); } public function can_edit_item_test() { $root = ORM::factory("item", 1); - access::allow(group::everybody(), "edit", $root); - $this->assert_true(access::group_can(group::everybody(), "edit", $root)); + access::allow(identity::everybody(), "edit", $root); + $this->assert_true(access::group_can(identity::everybody(), "edit", $root)); } public function non_view_permissions_propagate_down_test() { $root = ORM::factory("item", 1); $album = album::create($root, rand(), "test album"); - access::allow(group::everybody(), "edit", $root); - access::reset(group::everybody(), "edit", $album); - $this->assert_true(access::group_can(group::everybody(), "edit", $album)); + access::allow(identity::everybody(), "edit", $root); + access::reset(identity::everybody(), "edit", $album); + $this->assert_true(access::group_can(identity::everybody(), "edit", $album)); } public function non_view_permissions_can_be_revoked_lower_down_test() { @@ -279,36 +276,36 @@ class Access_Helper_Test extends Unit_Test_Case { $outer->reload(); $inner->reload(); - access::allow(group::everybody(), "edit", $root); - access::deny(group::everybody(), "edit", $outer); - access::allow(group::everybody(), "edit", $inner); + access::allow(identity::everybody(), "edit", $root); + access::deny(identity::everybody(), "edit", $outer); + access::allow(identity::everybody(), "edit", $inner); // Outer album is not editable, inner one is. - $this->assert_false(access::group_can(group::everybody(), "edit", $outer_photo)); - $this->assert_true(access::group_can(group::everybody(), "edit", $inner_photo)); + $this->assert_false(access::group_can(identity::everybody(), "edit", $outer_photo)); + $this->assert_true(access::group_can(identity::everybody(), "edit", $inner_photo)); } public function i_can_edit_test() { // Create a new user that belongs to no groups - $user = user::create("access_test", "Access Test", ""); + $user = identity::create_user("access_test", "Access Test", ""); foreach ($user->groups as $group) { $user->remove($group); } $user->save(); - user::set_active($user); + identity::set_active_user($user); // This user can't edit anything $root = ORM::factory("item", 1); $this->assert_false(access::can("edit", $root)); // Now add them to a group that has edit permission - $group = group::create("access_test"); + $group = identity::create_group("access_test"); $group->add($user); $group->save(); access::allow($group, "edit", $root); - $user = ORM::factory("user", $user->id); // reload() does not flush related columns - user::set_active($user); + $user = identity::lookup_user($user->id); // reload() does not flush related columns + identity::set_active_user($user); // And verify that the user can edit. $this->assert_true(access::can("edit", $root)); @@ -320,16 +317,16 @@ class Access_Helper_Test extends Unit_Test_Case { $this->assert_false(file_exists($album->file_path() . "/.htaccess")); - access::deny(group::everybody(), "view", $album); + access::deny(identity::everybody(), "view", $album); $this->assert_true(file_exists($album->file_path() . "/.htaccess")); - access::allow(group::everybody(), "view", $album); + access::allow(identity::everybody(), "view", $album); $this->assert_false(file_exists($album->file_path() . "/.htaccess")); - access::deny(group::everybody(), "view", $album); + access::deny(identity::everybody(), "view", $album); $this->assert_true(file_exists($album->file_path() . "/.htaccess")); - access::reset(group::everybody(), "view", $album); + access::reset(identity::everybody(), "view", $album); $this->assert_false(file_exists($album->file_path() . "/.htaccess")); } @@ -341,44 +338,44 @@ class Access_Helper_Test extends Unit_Test_Case { $this->assert_false(file_exists($album->resize_path() . "/.htaccess")); $this->assert_false(file_exists($album->thumb_path() . "/.htaccess")); - access::deny(group::everybody(), "view_full", $album); + access::deny(identity::everybody(), "view_full", $album); $this->assert_true(file_exists($album->file_path() . "/.htaccess")); $this->assert_false(file_exists($album->resize_path() . "/.htaccess")); $this->assert_false(file_exists($album->thumb_path() . "/.htaccess")); - access::allow(group::everybody(), "view_full", $album); + access::allow(identity::everybody(), "view_full", $album); $this->assert_false(file_exists($album->file_path() . "/.htaccess")); $this->assert_false(file_exists($album->resize_path() . "/.htaccess")); $this->assert_false(file_exists($album->thumb_path() . "/.htaccess")); - access::deny(group::everybody(), "view_full", $album); + access::deny(identity::everybody(), "view_full", $album); $this->assert_true(file_exists($album->file_path() . "/.htaccess")); $this->assert_false(file_exists($album->resize_path() . "/.htaccess")); $this->assert_false(file_exists($album->thumb_path() . "/.htaccess")); - access::reset(group::everybody(), "view_full", $album); + access::reset(identity::everybody(), "view_full", $album); $this->assert_false(file_exists($album->file_path() . "/.htaccess")); $this->assert_false(file_exists($album->resize_path() . "/.htaccess")); $this->assert_false(file_exists($album->thumb_path() . "/.htaccess")); } public function moved_items_inherit_new_permissions_test() { - user::set_active(user::lookup_by_name("admin")); + identity::set_active_user(identity::lookup_user_by_name("admin")); $root = ORM::factory("item", 1); $public_album = album::create($root, rand(), "public album"); $public_photo = photo::create($public_album, MODPATH . "gallery/images/gallery.png", "", ""); - access::allow(group::everybody(), "view", $public_album); + access::allow(identity::everybody(), "view", $public_album); $root->reload(); // Account for MPTT changes $private_album = album::create($root, rand(), "private album"); - access::deny(group::everybody(), "view", $private_album); + access::deny(identity::everybody(), "view", $private_album); $private_photo = photo::create($private_album, MODPATH . "gallery/images/gallery.png", "", ""); // Make sure that we now have a public photo and private photo. - $this->assert_true(access::group_can(group::everybody(), "view", $public_photo)); - $this->assert_false(access::group_can(group::everybody(), "view", $private_photo)); + $this->assert_true(access::group_can(identity::everybody(), "view", $public_photo)); + $this->assert_false(access::group_can(identity::everybody(), "view", $private_photo)); // Swap the photos item::move($public_photo, $private_album); @@ -394,7 +391,7 @@ class Access_Helper_Test extends Unit_Test_Case { $public_photo->reload(); // Make sure that the public_photo is now private, and the private_photo is now public. - $this->assert_false(access::group_can(group::everybody(), "view", $public_photo)); - $this->assert_true(access::group_can(group::everybody(), "view", $private_photo)); + $this->assert_false(access::group_can(identity::everybody(), "view", $public_photo)); + $this->assert_true(access::group_can(identity::everybody(), "view", $private_photo)); } } diff --git a/modules/gallery/tests/Albums_Controller_Test.php b/modules/gallery/tests/Albums_Controller_Test.php index d65946c7..8562355c 100644 --- a/modules/gallery/tests/Albums_Controller_Test.php +++ b/modules/gallery/tests/Albums_Controller_Test.php @@ -19,13 +19,13 @@ */ class Albums_Controller_Test extends Unit_Test_Case { public function setup() { - $this->_post = $_POST; - $this->_album = null; + $this->_save = array($_POST, $_SERVER); + $_SERVER["HTTP_REFERER"] = "HTTP_REFERER"; } public function teardown() { - $_POST = $this->_post; - if ($this->_album) { + list($_POST, $_SERVER) = $this->_save; + if (isset($this->_album)) { $this->_album->delete(); } } @@ -43,8 +43,9 @@ class Albums_Controller_Test extends Unit_Test_Case { $_POST["column"] = "weight"; $_POST["direction"] = "ASC"; $_POST["csrf"] = access::csrf_token(); + $_POST["slug"] = "new-name"; $_POST["_method"] = "put"; - access::allow(group::everybody(), "edit", $root); + access::allow(identity::everybody(), "edit", $root); ob_start(); $controller->_update($this->_album); @@ -52,7 +53,7 @@ class Albums_Controller_Test extends Unit_Test_Case { ob_end_clean(); $this->assert_equal( - json_encode(array("result" => "success")), + json_encode(array("result" => "success", "location" => "HTTP_REFERER")), $results); $this->assert_equal("new title", $this->_album->title); $this->assert_equal("new description", $this->_album->description); @@ -68,7 +69,7 @@ class Albums_Controller_Test extends Unit_Test_Case { $_POST["name"] = "new name"; $_POST["title"] = "new title"; $_POST["description"] = "new description"; - access::allow(group::everybody(), "edit", $root); + access::allow(identity::everybody(), "edit", $root); try { $controller->_update($this->_album); diff --git a/modules/gallery/tests/Controller_Auth_Test.php b/modules/gallery/tests/Controller_Auth_Test.php index caf6d8f2..0a7076c6 100644 --- a/modules/gallery/tests/Controller_Auth_Test.php +++ b/modules/gallery/tests/Controller_Auth_Test.php @@ -25,13 +25,18 @@ class Controller_Auth_Test extends Unit_Test_Case { public function find_missing_auth_test() { $found = array(); - $controllers = glob("*/*/controllers/*.php"); - $feeds = glob("*/*/helpers/*_rss.php"); + $controllers = explode("\n", `git ls-files '*/*/controllers/*.php'`); + $feeds = explode("\n", `git ls-files '*/*/helpers/*_rss.php'`); foreach (array_merge($controllers, $feeds) as $controller) { if (preg_match("{modules/(gallery_)?unit_test/}", $controller)) { continue; } + if (!$controller) { + // The last entry in each list from git ls-files appears to be an empty line + continue; + } + // List of all tokens without whitespace, simplifying parsing. $tokens = array(); foreach (token_get_all(file_get_contents($controller)) as $token) { @@ -118,7 +123,7 @@ class Controller_Auth_Test extends Unit_Test_Case { if ($token[1] == "access" && self::_token_matches(array(T_DOUBLE_COLON, "::"), $tokens, $token_number + 1) && self::_token_matches(array(T_STRING), $tokens, $token_number + 2) && - in_array($tokens[$token_number + 2][1], array("forbidden", "required")) && + in_array($tokens[$token_number + 2][1], array("forbidden", "required")) && self::_token_matches("(", $tokens, $token_number + 3)) { $token_number += 3; $function->checks_authorization(true); @@ -149,7 +154,7 @@ class Controller_Auth_Test extends Unit_Test_Case { } } } - } + } } // Generate the report diff --git a/modules/gallery/tests/Database_Test.php b/modules/gallery/tests/Database_Test.php index d83212ad..ad2bbba1 100644 --- a/modules/gallery/tests/Database_Test.php +++ b/modules/gallery/tests/Database_Test.php @@ -99,7 +99,7 @@ class Database_Test extends Unit_Test_Case { UNIQUE KEY(`name`)) ENGINE=InnoDB DEFAULT CHARSET=utf8"; $this->assert_same($expected, $converted); - + $sql = "UPDATE {test_tables} SET `name` = '{test string}' " . "WHERE `item_id` IN " . " (SELECT `id` FROM {items} " . @@ -116,12 +116,16 @@ class Database_Test extends Unit_Test_Case { $this->assert_same($expected, $sql); } - public function setup() { - } + function prefix_no_replacement_test() { + $update = Database_For_Test::instance()->from("test_tables") + ->where("1 = 1") + ->set(array("name" => "Test Name")) + ->update(); - public function teardown() { - } + $expected = "UPDATE `g3test_test_tables` SET `name` = 'Test Name' WHERE 1 = 1"; + $this->assert_same($expected, $update); + } } class Database_For_Test extends Database { @@ -131,4 +135,12 @@ class Database_For_Test extends Database { $db->config["table_prefix"] = "g3test_"; return $db; } + + public function query($sql = '') { + if (!empty($sql)) { + print " query($sql)\n"; + $sql = $this->add_table_prefixes($sql); + } + return $sql; + } } diff --git a/modules/gallery/tests/DrawForm_Test.php b/modules/gallery/tests/DrawForm_Test.php index dde54257..7ee80ca2 100644 --- a/modules/gallery/tests/DrawForm_Test.php +++ b/modules/gallery/tests/DrawForm_Test.php @@ -19,14 +19,14 @@ */ class DrawForm_Test extends Unit_Test_Case { function no_group_test() { - $form = new Forge("test/controller", "", "post", array("id" => "gTestGroupForm")); + $form = new Forge("test/controller", "", "post", array("id" => "g-test-group-form")); $form->input("title")->label(t("Title")); $form->textarea("description")->label(t("Text Area")); $form->submit("")->value(t("Submit")); $rendered = $form->__toString(); $expected = "<form action=\"http://./index.php/test/controller\" method=\"post\" " . - "id=\"gTestGroupForm\">\n" . + "id=\"g-test-group-form\">\n" . "<input type=\"hidden\" name=\"csrf\" value=\"" . access::csrf_token() . "\" />\n" . " <ul>\n" . " <li>\n" . @@ -48,7 +48,7 @@ class DrawForm_Test extends Unit_Test_Case { } function group_test() { - $form = new Forge("test/controller", "", "post", array("id" => "gTestGroupForm")); + $form = new Forge("test/controller", "", "post", array("id" => "g-test-group-form")); $group = $form->group("test_group")->label(t("Test Group")); $group->input("title")->label(t("Title")); $group->textarea("description")->label(t("Text Area")); @@ -56,7 +56,7 @@ class DrawForm_Test extends Unit_Test_Case { $rendered = $form->__toString(); $expected = "<form action=\"http://./index.php/test/controller\" method=\"post\" " . - "id=\"gTestGroupForm\">\n" . + "id=\"g-test-group-form\">\n" . "<input type=\"hidden\" name=\"csrf\" value=\"" . access::csrf_token() . "\" />\n" . " <fieldset>\n" . " <legend>Test Group</legend>\n" . @@ -81,7 +81,7 @@ class DrawForm_Test extends Unit_Test_Case { } function form_script_test() { - $form = new Forge("test/controller", "", "post", array("id" => "gTestGroupForm")); + $form = new Forge("test/controller", "", "post", array("id" => "g-test-group-form")); $group = $form->group("test_group")->label(t("Test Group")); $group->input("title")->label(t("Title")); $group->textarea("description")->label(t("Text Area")); @@ -92,7 +92,7 @@ class DrawForm_Test extends Unit_Test_Case { $rendered = $form->__toString(); $expected = "<form action=\"http://./index.php/test/controller\" method=\"post\" " . - "id=\"gTestGroupForm\">\n" . + "id=\"g-test-group-form\">\n" . "<input type=\"hidden\" name=\"csrf\" value=\"" . access::csrf_token() . "\" />\n" . " <fieldset>\n" . " <legend>Test Group</legend>\n" . diff --git a/modules/gallery/tests/File_Structure_Test.php b/modules/gallery/tests/File_Structure_Test.php index 9018f4c6..36342fda 100644 --- a/modules/gallery/tests/File_Structure_Test.php +++ b/modules/gallery/tests/File_Structure_Test.php @@ -17,6 +17,8 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */ +require_once(MODPATH . "gallery/tests/Gallery_Filters.php"); + class File_Structure_Test extends Unit_Test_Case { public function no_trailing_closing_php_tag_test() { $dir = new GalleryCodeFilterIterator( @@ -233,7 +235,9 @@ class File_Structure_Test extends Unit_Test_Case { foreach ($info_files as $file) { foreach (file($file) as $line) { $parts = explode("=", $line, 2); - $values[trim($parts[0])] = trim($parts[1]); + if (isset($parts[1])) { + $values[trim($parts[0])] = trim($parts[1]); + } } $module = dirname($file); @@ -261,33 +265,3 @@ class File_Structure_Test extends Unit_Test_Case { } } } - -class PhpCodeFilterIterator extends FilterIterator { - public function accept() { - $path_name = $this->getInnerIterator()->getPathName(); - return substr($path_name, -4) == ".php"; - } -} - -class GalleryCodeFilterIterator extends FilterIterator { - public function accept() { - // Skip anything that we didn"t write - $path_name = $this->getInnerIterator()->getPathName(); - return !( - strpos($path_name, ".svn") || - strpos($path_name, DOCROOT . "test") !== false || - strpos($path_name, DOCROOT . "var") !== false || - strpos($path_name, MODPATH . "forge") !== false || - strpos($path_name, MODPATH . "gallery/views/kohana_error_page.php") !== false || - strpos($path_name, MODPATH . "gallery/views/kohana_profiler.php") !== false || - strpos($path_name, MODPATH . "gallery_unit_test/views/kohana_error_page.php") !== false || - strpos($path_name, MODPATH . "gallery_unit_test/views/kohana_unit_test_cli.php") !== false || - strpos($path_name, MODPATH . "unit_test") !== false || - strpos($path_name, MODPATH . "exif/lib") !== false || - strpos($path_name, MODPATH . "user/lib/PasswordHash") !== false || - strpos($path_name, DOCROOT . "lib/swfupload") !== false || - strpos($path_name, SYSPATH) !== false || - strpos($path_name, MODPATH . "gallery/libraries/HTMLPurifier") !== false || - substr($path_name, -1, 1) == "~"); - } -} diff --git a/modules/gallery/tests/Gallery_Filters.php b/modules/gallery/tests/Gallery_Filters.php new file mode 100644 index 00000000..d1bc2cfa --- /dev/null +++ b/modules/gallery/tests/Gallery_Filters.php @@ -0,0 +1,48 @@ +<?php defined("SYSPATH") or die("No direct script access."); +/** + * Gallery - a web based photo album viewer and editor + * Copyright (C) 2000-2009 Bharat Mediratta + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or (at + * your option) any later version. + * + * This program is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. + */ +class PhpCodeFilterIterator extends FilterIterator { + public function accept() { + $path_name = $this->getInnerIterator()->getPathName(); + return substr($path_name, -4) == ".php"; + } +} + +class GalleryCodeFilterIterator extends FilterIterator { + public function accept() { + // Skip anything that we didn"t write + $path_name = $this->getInnerIterator()->getPathName(); + return !( + strpos($path_name, ".svn") || + strpos($path_name, DOCROOT . "test") !== false || + strpos($path_name, DOCROOT . "var") !== false || + strpos($path_name, MODPATH . "forge") !== false || + strpos($path_name, MODPATH . "gallery/views/kohana_error_page.php") !== false || + strpos($path_name, MODPATH . "gallery/views/kohana_profiler.php") !== false || + strpos($path_name, MODPATH . "gallery_unit_test/views/kohana_error_page.php") !== false || + strpos($path_name, MODPATH . "gallery_unit_test/views/kohana_unit_test_cli.php") !== false || + strpos($path_name, MODPATH . "unit_test") !== false || + strpos($path_name, MODPATH . "exif/lib") !== false || + strpos($path_name, MODPATH . "user/lib/PasswordHash") !== false || + strpos($path_name, DOCROOT . "lib/swfupload") !== false || + strpos($path_name, SYSPATH) !== false || + strpos($path_name, MODPATH . "gallery/libraries/HTMLPurifier") !== false || + substr($path_name, -1, 1) == "~"); + } +} diff --git a/modules/gallery/tests/Item_Helper_Test.php b/modules/gallery/tests/Item_Helper_Test.php index 33fcdb73..a364423a 100644 --- a/modules/gallery/tests/Item_Helper_Test.php +++ b/modules/gallery/tests/Item_Helper_Test.php @@ -23,16 +23,16 @@ class Item_Helper_Test extends Unit_Test_Case { $root = ORM::factory("item", 1); $album = album::create($root, rand(), rand(), rand()); $item = self::_create_random_item($album); - user::set_active(user::guest()); + identity::set_active_user(identity::guest()); // We can see the item when permissions are granted - access::allow(group::everybody(), "view", $album); + access::allow(identity::everybody(), "view", $album); $this->assert_equal( 1, ORM::factory("item")->viewable()->where("id", $item->id)->count_all()); // We can't see the item when permissions are denied - access::deny(group::everybody(), "view", $album); + access::deny(identity::everybody(), "view", $album); $this->assert_equal( 0, ORM::factory("item")->viewable()->where("id", $item->id)->count_all()); diff --git a/modules/gallery/tests/Item_Model_Test.php b/modules/gallery/tests/Item_Model_Test.php index 84210e4c..e7dce893 100644 --- a/modules/gallery/tests/Item_Model_Test.php +++ b/modules/gallery/tests/Item_Model_Test.php @@ -24,12 +24,11 @@ class Item_Model_Test extends Unit_Test_Case { $this->assert_true(!empty($item->updated)); } - private static function _create_random_item() { - $item = ORM::factory("item"); - /* Set all required fields (values are irrelevant) */ - $item->name = rand(); - $item->type = "photo"; - return $item->add_to_parent(ORM::factory("item", 1)); + private static function _create_random_item($root=null, $rand=null) { + $root = $root ? $root : ORM::factory("item", 1); + $rand = $rand ? $rand : rand(); + $item = photo::create($root, MODPATH . "gallery/tests/test.jpg", "$rand.jpg", $rand, $rand); + return $item; } public function updating_doesnt_change_created_date_test() { @@ -62,7 +61,7 @@ class Item_Model_Test extends Unit_Test_Case { $this->assert_true(empty($item->updated)); } - public function move_photo_test() { + public function rename_photo_test() { // Create a test photo $item = self::_create_random_item(); @@ -86,14 +85,11 @@ class Item_Model_Test extends Unit_Test_Case { $this->assert_equal("file", file_get_contents($item->file_path())); } - public function move_album_test() { + public function rename_album_test() { // Create an album with a photo in it $root = ORM::factory("item", 1); $album = album::create($root, rand(), rand(), rand()); - $photo = ORM::factory("item"); - $photo->name = rand(); - $photo->type = "photo"; - $photo->add_to_parent($album); + $photo = self::_create_random_item($album); file_put_contents($photo->thumb_path(), "thumb"); file_put_contents($photo->resize_path(), "resize"); @@ -141,6 +137,24 @@ class Item_Model_Test extends Unit_Test_Case { $this->assert_false(true, "Item_Model::rename should not accept / characters"); } + public function item_rename_fails_with_existing_name_test() { + // Create a test photo + $item = self::_create_random_item(); + $item2 = self::_create_random_item(); + + $new_name = $item2->name; + + try { + $item->rename($new_name)->save(); + } catch (Exception $e) { + // pass + $this->assert_true(strpos($e->getMessage(), "INVALID_RENAME_FILE_EXISTS") !== false, + "incorrect exception."); + return; + } + $this->assert_false(true, "Item_Model::rename should fail."); + } + public function save_original_values_test() { $item = self::_create_random_item(); $item->title = "ORIGINAL_VALUE"; @@ -160,4 +174,102 @@ class Item_Model_Test extends Unit_Test_Case { $this->assert_equal("foo%20bar", $item->relative_url()); $this->assert_equal("foo%20bar.jpg", $item->relative_path()); } + + public function move_album_test() { + // Create an album with a photo in it + $root = ORM::factory("item", 1); + $album2 = album::create($root, rand(), rand(), rand()); + $album = album::create($album2, rand(), rand(), rand()); + $photo = self::_create_random_item($album); + + file_put_contents($photo->thumb_path(), "thumb"); + file_put_contents($photo->resize_path(), "resize"); + file_put_contents($photo->file_path(), "file"); + + // Now move the album + $album->move_to($root); + $photo->reload(); + + // Expected: + // * the album dirs are all moved + // * the photo's paths are all inside the albums paths + // * the photo files are all still intact and accessible + + $this->assert_same(0, strpos($photo->file_path(), $album->file_path())); + $this->assert_same(0, strpos($photo->thumb_path(), dirname($album->thumb_path()))); + $this->assert_same(0, strpos($photo->resize_path(), dirname($album->resize_path()))); + + $this->assert_equal("thumb", file_get_contents($photo->thumb_path())); + $this->assert_equal("resize", file_get_contents($photo->resize_path())); + $this->assert_equal("file", file_get_contents($photo->file_path())); + } + + public function move_photo_test() { + // Create an album with a photo in it + $root = ORM::factory("item", 1); + $album2 = album::create($root, rand(), rand(), rand()); + $album = album::create($album2, rand(), rand(), rand()); + $photo = self::_create_random_item($album); + + file_put_contents($photo->thumb_path(), "thumb"); + file_put_contents($photo->resize_path(), "resize"); + file_put_contents($photo->file_path(), "file"); + + // Now move the album + $photo->move_to($album2); + $photo->reload(); + + // Expected: + // * the album dirs are all moved + // * the photo's paths are all inside the albums paths + // * the photo files are all still intact and accessible + + $this->assert_same(0, strpos($photo->file_path(), $album->file_path())); + $this->assert_same(0, strpos($photo->thumb_path(), dirname($album->thumb_path()))); + $this->assert_same(0, strpos($photo->resize_path(), dirname($album->resize_path()))); + + $this->assert_equal("thumb", file_get_contents($photo->thumb_path())); + $this->assert_equal("resize", file_get_contents($photo->resize_path())); + $this->assert_equal("file", file_get_contents($photo->file_path())); + } + + public function move_album_fails_invalid_target_test() { + // Create an album with a photo in it + $root = ORM::factory("item", 1); + $name = rand(); + $album = album::create($root, $name, $name, $name); + $source = album::create($album, $name, $name, $name); + + try { + $source->move_to($root); + } catch (Exception $e) { + // pass + $this->assert_true(strpos($e->getMessage(), "INVALID_MOVE_TARGET_EXISTS") !== false, + "incorrect exception."); + return; + } + + $this->assert_false(true, "Item_Model::rename should not accept / characters"); + } + + public function move_photo_fails_invalid_target_test() { + // Create an album with a photo in it + $root = ORM::factory("item", 1); + $photo_name = rand(); + $photo1 = self::_create_random_item($root, $photo_name); + $name = rand(); + $album = album::create($root, $name, $name, $name); + $photo2 = self::_create_random_item($album, $photo_name); + + try { + $photo2->move_to($root); + } catch (Exception $e) { + // pass + $this->assert_true(strpos($e->getMessage(), "INVALID_MOVE_TARGET_EXISTS") !== false, + "incorrect exception."); + return; + } + + $this->assert_false(true, "Item_Model::rename should not accept / characters"); + } } diff --git a/modules/gallery/tests/Photos_Controller_Test.php b/modules/gallery/tests/Photos_Controller_Test.php index 0159b420..624e6878 100644 --- a/modules/gallery/tests/Photos_Controller_Test.php +++ b/modules/gallery/tests/Photos_Controller_Test.php @@ -19,11 +19,12 @@ */ class Photos_Controller_Test extends Unit_Test_Case { public function setup() { - $this->_post = $_POST; + $this->_save = array($_POST, $_SERVER); + $_SERVER["HTTP_REFERER"] = "HTTP_REFERER"; } public function teardown() { - $_POST = $this->_post; + list($_POST, $_SERVER) = $this->_save; } public function change_photo_test() { @@ -31,7 +32,7 @@ class Photos_Controller_Test extends Unit_Test_Case { $root = ORM::factory("item", 1); $photo = photo::create( $root, MODPATH . "gallery/tests/test.jpg", "test.jpeg", - "test", "test", user::active(), "slug"); + "test", "test", identity::active_user()->id, "slug"); $orig_name = $photo->name; $_POST["filename"] = "test.jpeg"; @@ -40,14 +41,15 @@ class Photos_Controller_Test extends Unit_Test_Case { $_POST["description"] = "new description"; $_POST["slug"] = "new-slug"; $_POST["csrf"] = access::csrf_token(); - access::allow(group::everybody(), "edit", $root); + access::allow(identity::everybody(), "edit", $root); ob_start(); $controller->_update($photo); $results = ob_get_contents(); ob_end_clean(); - $this->assert_equal(json_encode(array("result" => "success")), $results); + $this->assert_equal( + json_encode(array("result" => "success", "location" => "HTTP_REFERER")), $results); $this->assert_equal("new-slug", $photo->slug); $this->assert_equal("new title", $photo->title); $this->assert_equal("new description", $photo->description); @@ -64,7 +66,7 @@ class Photos_Controller_Test extends Unit_Test_Case { $_POST["name"] = "new name"; $_POST["title"] = "new title"; $_POST["description"] = "new description"; - access::allow(group::everybody(), "edit", $root); + access::allow(identity::everybody(), "edit", $root); try { $controller->_update($photo); diff --git a/modules/gallery/tests/Xss_Security_Test.php b/modules/gallery/tests/Xss_Security_Test.php index 16541017..b296d97c 100644 --- a/modules/gallery/tests/Xss_Security_Test.php +++ b/modules/gallery/tests/Xss_Security_Test.php @@ -248,7 +248,7 @@ class Xss_Security_Test extends Unit_Test_Case { $frame->is_safe_attr(true); } } - } + } } else if ($frame && $token[0] == T_OBJECT_OPERATOR) { $frame->expr_append($token[1]); @@ -349,7 +349,7 @@ class Xss_Security_Test extends Unit_Test_Case { $canonical = MODPATH . "gallery/tests/xss_data.txt"; exec("diff $canonical $new", $output, $return_value); $this->assert_false( - $return_value, "XSS golden file mismatch. Output:\n" . implode("\n", $output) ); + $return_value, "XSS golden file mismatch. Output:\n" . implode("\n", $output) ); } private static function _create_frame($token, $in_script_block, diff --git a/modules/gallery/tests/controller_auth_data.txt b/modules/gallery/tests/controller_auth_data.txt index fdf00c5e..30102538 100644 --- a/modules/gallery/tests/controller_auth_data.txt +++ b/modules/gallery/tests/controller_auth_data.txt @@ -9,6 +9,11 @@ modules/gallery/controllers/albums.php _form_add modules/gallery/controllers/combined.php javascript DIRTY_AUTH modules/gallery/controllers/combined.php css DIRTY_AUTH modules/gallery/controllers/file_proxy.php __call DIRTY_CSRF|DIRTY_AUTH +modules/gallery/controllers/login.php ajax DIRTY_AUTH +modules/gallery/controllers/login.php auth_ajax DIRTY_AUTH +modules/gallery/controllers/login.php html DIRTY_AUTH +modules/gallery/controllers/login.php auth_html DIRTY_AUTH +modules/gallery/controllers/logout.php index DIRTY_CSRF|DIRTY_AUTH modules/gallery/controllers/maintenance.php index DIRTY_AUTH modules/gallery/controllers/rest.php __construct DIRTY_AUTH modules/gallery/controllers/rest.php __call DIRTY_AUTH @@ -31,10 +36,5 @@ modules/server_add/controllers/admin_server_add.php autocomplete modules/server_add/controllers/server_add.php children DIRTY_CSRF modules/tag/controllers/admin_tags.php index DIRTY_CSRF modules/tag/controllers/tags.php _show DIRTY_CSRF|DIRTY_AUTH -modules/user/controllers/login.php ajax DIRTY_AUTH -modules/user/controllers/login.php auth_ajax DIRTY_AUTH -modules/user/controllers/login.php html DIRTY_AUTH -modules/user/controllers/login.php auth_html DIRTY_AUTH -modules/user/controllers/logout.php index DIRTY_CSRF|DIRTY_AUTH modules/user/controllers/password.php reset DIRTY_AUTH modules/user/controllers/password.php do_reset DIRTY_CSRF|DIRTY_AUTH diff --git a/modules/gallery/tests/selenium/Add_Comment.html b/modules/gallery/tests/selenium/Add_Comment.html index b4b96ed2..054e7597 100644 --- a/modules/gallery/tests/selenium/Add_Comment.html +++ b/modules/gallery/tests/selenium/Add_Comment.html @@ -18,22 +18,22 @@ </tr> <tr> <td>clickAndWait</td> - <td>gPhotoId-2</td> + <td>g-photo-id-2</td> <td></td> </tr> <tr> <td>type</td> - <td>gAuthor</td> + <td>g-author</td> <td>Test</td> </tr> <tr> <td>type</td> - <td>gEmail</td> + <td>g-email</td> <td>test@gmail.com</td> </tr> <tr> <td>type</td> - <td>gText</td> + <td>g-text</td> <td>This is a selenium test comment.</td> </tr> <tr> diff --git a/modules/gallery/tests/selenium/Login.html b/modules/gallery/tests/selenium/Login.html index 5e17a3c7..d2e45c63 100644 --- a/modules/gallery/tests/selenium/Login.html +++ b/modules/gallery/tests/selenium/Login.html @@ -18,17 +18,17 @@ </tr> <tr> <td>click</td> - <td>gLoginLink</td> + <td>g-login-link</td> <td></td> </tr> <tr> <td>type</td> - <td>gName</td> + <td>g-name</td> <td>admin</td> </tr> <tr> <td>type</td> - <td>gPassword</td> + <td>g-password</td> <td>admin</td> </tr> <tr> @@ -38,7 +38,7 @@ </tr> <tr> <td>clickAndWait</td> - <td>gUserProfileLink</td> + <td>g-user-profile-link</td> <td></td> </tr> diff --git a/modules/gallery/tests/xss_data.txt b/modules/gallery/tests/xss_data.txt index ff4a78a5..9146ddb2 100644 --- a/modules/gallery/tests/xss_data.txt +++ b/modules/gallery/tests/xss_data.txt @@ -1,24 +1,24 @@ modules/akismet/views/admin_akismet.html.php 16 DIRTY $form modules/akismet/views/admin_akismet_stats.html.php 9 DIRTY_ATTR $api_key modules/akismet/views/admin_akismet_stats.html.php 9 DIRTY_ATTR urlencode($blog_url) -modules/comment/views/admin_block_recent_comments.html.php 4 DIRTY_ATTR ($i%2==0)?"gEvenRow":"gOddRow" +modules/comment/views/admin_block_recent_comments.html.php 4 DIRTY_ATTR text::alternate("g-even","g-odd") modules/comment/views/admin_block_recent_comments.html.php 5 DIRTY_ATTR $comment->author()->avatar_url(32,$theme->url(,true)) modules/comment/views/admin_block_recent_comments.html.php 10 DIRTY gallery::date_time($comment->created) -modules/comment/views/admin_comments.html.php 42 DIRTY $menu -modules/comment/views/admin_comments.html.php 106 DIRTY_ATTR $comment->id -modules/comment/views/admin_comments.html.php 106 DIRTY_ATTR ($i%2==0)?"gOddRow":"gEvenRow" -modules/comment/views/admin_comments.html.php 109 DIRTY_ATTR $comment->author()->avatar_url(40,$theme->url(,true)) -modules/comment/views/admin_comments.html.php 122 DIRTY_JS $item->url() -modules/comment/views/admin_comments.html.php 124 DIRTY_ATTR $item->thumb_url() -modules/comment/views/admin_comments.html.php 126 DIRTY photo::img_dimensions($item->thumb_width,$item->thumb_height,75) -modules/comment/views/admin_comments.html.php 134 DIRTY gallery::date($comment->created) -modules/comment/views/admin_comments.html.php 141 DIRTY_JS $comment->id -modules/comment/views/admin_comments.html.php 150 DIRTY_JS $comment->id -modules/comment/views/admin_comments.html.php 159 DIRTY_JS $comment->id -modules/comment/views/admin_comments.html.php 168 DIRTY_JS $comment->id -modules/comment/views/admin_comments.html.php 175 DIRTY_JS $comment->id -modules/comment/views/admin_comments.html.php 183 DIRTY_JS $comment->id -modules/comment/views/admin_comments.html.php 196 DIRTY $pager +modules/comment/views/admin_comments.html.php 43 DIRTY $menu->render() +modules/comment/views/admin_comments.html.php 107 DIRTY_ATTR $comment->id +modules/comment/views/admin_comments.html.php 107 DIRTY_ATTR text::alternate("g-odd","g-even") +modules/comment/views/admin_comments.html.php 110 DIRTY_ATTR $comment->author()->avatar_url(40,$theme->url(,true)) +modules/comment/views/admin_comments.html.php 123 DIRTY_JS $item->url() +modules/comment/views/admin_comments.html.php 125 DIRTY_ATTR $item->thumb_url() +modules/comment/views/admin_comments.html.php 127 DIRTY photo::img_dimensions($item->thumb_width,$item->thumb_height,75) +modules/comment/views/admin_comments.html.php 135 DIRTY gallery::date($comment->created) +modules/comment/views/admin_comments.html.php 142 DIRTY_JS $comment->id +modules/comment/views/admin_comments.html.php 151 DIRTY_JS $comment->id +modules/comment/views/admin_comments.html.php 160 DIRTY_JS $comment->id +modules/comment/views/admin_comments.html.php 169 DIRTY_JS $comment->id +modules/comment/views/admin_comments.html.php 176 DIRTY_JS $comment->id +modules/comment/views/admin_comments.html.php 184 DIRTY_JS $comment->id +modules/comment/views/admin_comments.html.php 197 DIRTY $pager modules/comment/views/comment.html.php 2 DIRTY_ATTR $comment->id; modules/comment/views/comment.html.php 5 DIRTY_ATTR $comment->author()->avatar_url(40,$theme->url(,true)) modules/comment/views/comment.mrss.php 10 DIRTY $feed->uri @@ -39,7 +39,8 @@ modules/digibug/views/digibug_form.html.php 5 DIRTY form:: modules/digibug/views/digibug_form.html.php 6 DIRTY form::close() modules/exif/views/exif_dialog.html.php 14 DIRTY $details[$i]["caption"] modules/exif/views/exif_dialog.html.php 21 DIRTY $details[$i]["caption"] -modules/g2_import/views/admin_g2_import.html.php 28 DIRTY $form +modules/g2_import/views/admin_g2_import.html.php 29 DIRTY $form +modules/gallery/views/admin_advanced_settings.html.php 21 DIRTY_ATTR text::alternate("g-odd","g-even") modules/gallery/views/admin_advanced_settings.html.php 22 DIRTY $var->module_name modules/gallery/views/admin_block_log_entries.html.php 4 DIRTY_ATTR log::severity_class($entry->severity) modules/gallery/views/admin_block_log_entries.html.php 6 DIRTY gallery::date_time($entry->timestamp) @@ -53,61 +54,74 @@ modules/gallery/views/admin_block_photo_stream.html.php 6 DIRTY photo: modules/gallery/views/admin_block_photo_stream.html.php 7 DIRTY_ATTR $photo->thumb_url() modules/gallery/views/admin_dashboard.html.php 5 DIRTY_JS $csrf modules/gallery/views/admin_dashboard.html.php 35 DIRTY $blocks -modules/gallery/views/admin_graphics.html.php 22 DIRTY newView("admin_graphics_none.html") -modules/gallery/views/admin_graphics.html.php 24 DIRTY newView("admin_graphics_$active.html",array("tk"=>$tk->$active,"is_active"=>true)) -modules/gallery/views/admin_graphics.html.php 31 DIRTY newView("admin_graphics_$id.html",array("tk"=>$tk->$id,"is_active"=>false)) -modules/gallery/views/admin_graphics_gd.html.php 2 DIRTY_ATTR $is_active?" gSelected":"" -modules/gallery/views/admin_graphics_gd.html.php 2 DIRTY_ATTR $tk->installed?" gInstalledToolkit":" gUnavailable" +modules/gallery/views/admin_graphics.html.php 24 DIRTY newView("admin_graphics_none.html") +modules/gallery/views/admin_graphics.html.php 26 DIRTY newView("admin_graphics_$active.html",array("tk"=>$tk->$active,"is_active"=>true)) +modules/gallery/views/admin_graphics.html.php 33 DIRTY newView("admin_graphics_$id.html",array("tk"=>$tk->$id,"is_active"=>false)) +modules/gallery/views/admin_graphics_gd.html.php 2 DIRTY_ATTR $is_active?" g-selected":"" +modules/gallery/views/admin_graphics_gd.html.php 2 DIRTY_ATTR $tk->installed?" g-installed-toolkit":" g-unavailable" modules/gallery/views/admin_graphics_gd.html.php 19 DIRTY $tk->error -modules/gallery/views/admin_graphics_graphicsmagick.html.php 2 DIRTY_ATTR $is_active?" gSelected":"" -modules/gallery/views/admin_graphics_graphicsmagick.html.php 2 DIRTY_ATTR $tk->installed?" gInstalledToolkit":" gUnavailable" +modules/gallery/views/admin_graphics_graphicsmagick.html.php 2 DIRTY_ATTR $is_active?" g-selected":"" +modules/gallery/views/admin_graphics_graphicsmagick.html.php 2 DIRTY_ATTR $tk->installed?" g-installed-toolkit":" g-unavailable" modules/gallery/views/admin_graphics_graphicsmagick.html.php 18 DIRTY $tk->error -modules/gallery/views/admin_graphics_imagemagick.html.php 2 DIRTY_ATTR $is_active?" gSelected":"" -modules/gallery/views/admin_graphics_imagemagick.html.php 2 DIRTY_ATTR $tk->installed?" gInstalledToolkit":" gUnavailable" +modules/gallery/views/admin_graphics_imagemagick.html.php 2 DIRTY_ATTR $is_active?" g-selected":"" +modules/gallery/views/admin_graphics_imagemagick.html.php 2 DIRTY_ATTR $tk->installed?" g-installed-toolkit":" g-unavailable" modules/gallery/views/admin_graphics_imagemagick.html.php 18 DIRTY $tk->error -modules/gallery/views/admin_languages.html.php 9 DIRTY access::csrf_form_field() -modules/gallery/views/admin_languages.html.php 27 DIRTY_ATTR (isset($installed_locales[$code]))?"installed":"" -modules/gallery/views/admin_languages.html.php 27 DIRTY_ATTR ($default_locale==$code)?" default":"" -modules/gallery/views/admin_languages.html.php 28 DIRTY form::checkbox("installed_locales[]",$code,isset($installed_locales[$code])) -modules/gallery/views/admin_languages.html.php 29 DIRTY $display_name -modules/gallery/views/admin_languages.html.php 31 DIRTY form::radio("default_locale",$code,($default_locale==$code),((isset($installed_locales[$code]))?'':'disabled="disabled"')) -modules/gallery/views/admin_languages.html.php 102 DIRTY $share_translations_form -modules/gallery/views/admin_maintenance.html.php 24 DIRTY_ATTR ($i%2==0)?"gOddRow":"gEvenRow" +modules/gallery/views/admin_identity.html.php 43 DIRTY access::csrf_form_field() +modules/gallery/views/admin_identity.html.php 50 DIRTY_ATTR text::alternate("g-odd","g-even") +modules/gallery/views/admin_identity.html.php 52 DIRTY form::radio($data,$module_name,$module_name==$active) +modules/gallery/views/admin_identity_confirm.html.php 3 DIRTY access::csrf_form_field() +modules/gallery/views/admin_identity_confirm.html.php 4 DIRTY form::hidden("provider",$new_provider) +modules/gallery/views/admin_languages.html.php 43 DIRTY access::csrf_form_field() +modules/gallery/views/admin_languages.html.php 60 DIRTY_ATTR (isset($installed_locales[$code]))?"g-available":"" +modules/gallery/views/admin_languages.html.php 60 DIRTY_ATTR ($default_locale==$code)?" g-selected":"" +modules/gallery/views/admin_languages.html.php 61 DIRTY form::checkbox("installed_locales[]",$code,isset($installed_locales[$code])) +modules/gallery/views/admin_languages.html.php 62 DIRTY $display_name +modules/gallery/views/admin_languages.html.php 64 DIRTY form::radio("default_locale",$code,($default_locale==$code),((isset($installed_locales[$code]))?'':'disabled="disabled"')) +modules/gallery/views/admin_languages.html.php 109 DIRTY $share_translations_form +modules/gallery/views/admin_maintenance.html.php 24 DIRTY_ATTR text::alternate("g-odd","g-even") modules/gallery/views/admin_maintenance.html.php 24 DIRTY_ATTR log::severity_class($task->severity) modules/gallery/views/admin_maintenance.html.php 25 DIRTY_ATTR log::severity_class($task->severity) modules/gallery/views/admin_maintenance.html.php 26 DIRTY $task->name modules/gallery/views/admin_maintenance.html.php 29 DIRTY $task->description -modules/gallery/views/admin_maintenance.html.php 72 DIRTY_ATTR ($i%2==0)?"gOddRow":"gEvenRow" -modules/gallery/views/admin_maintenance.html.php 72 DIRTY_ATTR $task->state=="stalled"?"gWarning":"" -modules/gallery/views/admin_maintenance.html.php 73 DIRTY_ATTR $task->state=="stalled"?"gWarning":"" -modules/gallery/views/admin_maintenance.html.php 74 DIRTY gallery::date_time($task->updated) -modules/gallery/views/admin_maintenance.html.php 77 DIRTY $task->name -modules/gallery/views/admin_maintenance.html.php 92 DIRTY $task->status -modules/gallery/views/admin_maintenance.html.php 145 DIRTY_ATTR ($i%2==0)?"gOddRow":"gEvenRow" -modules/gallery/views/admin_maintenance.html.php 145 DIRTY_ATTR $task->state=="success"?"gSuccess":"gError" -modules/gallery/views/admin_maintenance.html.php 146 DIRTY_ATTR $task->state=="success"?"gSuccess":"gError" -modules/gallery/views/admin_maintenance.html.php 147 DIRTY gallery::date_time($task->updated) -modules/gallery/views/admin_maintenance.html.php 150 DIRTY $task->name -modules/gallery/views/admin_maintenance.html.php 162 DIRTY $task->status +modules/gallery/views/admin_maintenance.html.php 70 DIRTY_ATTR text::alternate("g-odd","g-even") +modules/gallery/views/admin_maintenance.html.php 70 DIRTY_ATTR $task->state=="stalled"?"g-warning":"" +modules/gallery/views/admin_maintenance.html.php 71 DIRTY_ATTR $task->state=="stalled"?"g-warning":"" +modules/gallery/views/admin_maintenance.html.php 72 DIRTY gallery::date_time($task->updated) +modules/gallery/views/admin_maintenance.html.php 75 DIRTY $task->name +modules/gallery/views/admin_maintenance.html.php 90 DIRTY $task->status +modules/gallery/views/admin_maintenance.html.php 141 DIRTY_ATTR text::alternate("g-odd","g-even") +modules/gallery/views/admin_maintenance.html.php 141 DIRTY_ATTR $task->state=="success"?"g-success":"g-error" +modules/gallery/views/admin_maintenance.html.php 142 DIRTY_ATTR $task->state=="success"?"g-success":"g-error" +modules/gallery/views/admin_maintenance.html.php 143 DIRTY gallery::date_time($task->updated) +modules/gallery/views/admin_maintenance.html.php 146 DIRTY $task->name +modules/gallery/views/admin_maintenance.html.php 158 DIRTY $task->status modules/gallery/views/admin_maintenance_show_log.html.php 8 DIRTY_JS url::site("admin/maintenance/save_log/$task->id?csrf=$csrf") modules/gallery/views/admin_maintenance_show_log.html.php 13 DIRTY $task->name modules/gallery/views/admin_maintenance_task.html.php 55 DIRTY $task->name -modules/gallery/views/admin_modules.html.php 9 DIRTY access::csrf_form_field() -modules/gallery/views/admin_modules.html.php 19 DIRTY_ATTR ($i%2==0)?"gOddRow":"gEvenRow" +modules/gallery/views/admin_modules.html.php 10 DIRTY access::csrf_form_field() +modules/gallery/views/admin_modules.html.php 19 DIRTY_ATTR text::alternate("g-odd","g-even") modules/gallery/views/admin_modules.html.php 22 DIRTY form::checkbox($data,'1',module::is_active($module_name)) modules/gallery/views/admin_modules.html.php 24 DIRTY $module_info->version -modules/gallery/views/admin_theme_options.html.php 5 DIRTY $form +modules/gallery/views/admin_sidebar.html.php 50 DIRTY $available +modules/gallery/views/admin_sidebar.html.php 58 DIRTY $active +modules/gallery/views/admin_sidebar_blocks.html.php 4 DIRTY_ATTR $ref +modules/gallery/views/admin_sidebar_blocks.html.php 4 DIRTY $text +modules/gallery/views/admin_theme_options.html.php 6 DIRTY $form modules/gallery/views/admin_themes.html.php 3 DIRTY_JS url::site("admin/themes/choose") modules/gallery/views/admin_themes.html.php 5 DIRTY_JS $csrf -modules/gallery/views/admin_themes.html.php 20 DIRTY $themes[$site]->name -modules/gallery/views/admin_themes.html.php 22 DIRTY $themes[$site]->description -modules/gallery/views/admin_themes.html.php 36 DIRTY $info->name -modules/gallery/views/admin_themes.html.php 38 DIRTY $info->description -modules/gallery/views/admin_themes.html.php 58 DIRTY $themes[$admin]->name -modules/gallery/views/admin_themes.html.php 60 DIRTY $themes[$admin]->description -modules/gallery/views/admin_themes.html.php 74 DIRTY $info->name -modules/gallery/views/admin_themes.html.php 76 DIRTY $info->description +modules/gallery/views/admin_themes.html.php 22 DIRTY $themes[$site]->name +modules/gallery/views/admin_themes.html.php 24 DIRTY $themes[$site]->description +modules/gallery/views/admin_themes.html.php 38 DIRTY $info->name +modules/gallery/views/admin_themes.html.php 40 DIRTY $info->description +modules/gallery/views/admin_themes.html.php 60 DIRTY $themes[$admin]->name +modules/gallery/views/admin_themes.html.php 62 DIRTY $themes[$admin]->description +modules/gallery/views/admin_themes.html.php 76 DIRTY $info->name +modules/gallery/views/admin_themes.html.php 78 DIRTY $info->description modules/gallery/views/admin_themes_preview.html.php 7 DIRTY_ATTR $url +modules/gallery/views/in_place_edit.html.php 2 DIRTY form::open($action,array("method"=>"post","id"=>"g-in-place-edit-form","class"=>"g-short-form"),$hidden) +modules/gallery/views/in_place_edit.html.php 5 DIRTY form::input("input",$form["input"]," class='textbox'") +modules/gallery/views/in_place_edit.html.php 12 DIRTY form::close() +modules/gallery/views/in_place_edit.html.php 14 DIRTY $errors["input"] modules/gallery/views/kohana_error_page.php 102 DIRTY $message modules/gallery/views/kohana_error_page.php 116 DIRTY $trace modules/gallery/views/kohana_profiler.php 32 DIRTY $profile->render(); @@ -125,7 +139,23 @@ modules/gallery/views/l10n_client.html.php 54 DIRTY form:: modules/gallery/views/l10n_client.html.php 58 DIRTY form::textarea("l10n-edit-plural-translation-few","",' rows="2"') modules/gallery/views/l10n_client.html.php 62 DIRTY form::textarea("l10n-edit-plural-translation-many","",' rows="2"') modules/gallery/views/l10n_client.html.php 67 DIRTY form::textarea("l10n-edit-plural-translation-other","",' rows="2"') -modules/gallery/views/maintenance.html.php 46 DIRTY user::get_login_form("login/auth_html") +modules/gallery/views/login_ajax.html.php 6 DIRTY_JS url::site("password/reset") +modules/gallery/views/login_ajax.html.php 37 DIRTY $form +modules/gallery/views/maintenance.html.php 46 DIRTY auth::get_login_form("login/auth_html") +modules/gallery/views/menu.html.php 4 DIRTY isset($menu->css_id)?"id='$menu->css_id'":"" +modules/gallery/views/menu.html.php 4 DIRTY_ATTR $menu->css_class +modules/gallery/views/menu.html.php 6 DIRTY $element->render() +modules/gallery/views/menu.html.php 18 DIRTY $element->render() +modules/gallery/views/menu_ajax_link.html.php 3 DIRTY_ATTR $menu->css_id +modules/gallery/views/menu_ajax_link.html.php 4 DIRTY_ATTR $menu->css_class +modules/gallery/views/menu_ajax_link.html.php 5 DIRTY_JS $menu->url +modules/gallery/views/menu_ajax_link.html.php 7 DIRTY $menu->ajax_handler +modules/gallery/views/menu_dialog.html.php 3 DIRTY_ATTR $menu->css_id +modules/gallery/views/menu_dialog.html.php 4 DIRTY_ATTR $menu->css_class +modules/gallery/views/menu_dialog.html.php 5 DIRTY_JS $menu->url +modules/gallery/views/menu_link.html.php 3 DIRTY_ATTR $menu->css_id +modules/gallery/views/menu_link.html.php 4 DIRTY_ATTR $menu->css_class +modules/gallery/views/menu_link.html.php 5 DIRTY_JS $menu->url modules/gallery/views/move_browse.html.php 4 DIRTY_JS url::site("move/show_sub_tree/{$source->id}/__TARGETID__") modules/gallery/views/move_browse.html.php 39 DIRTY $tree modules/gallery/views/move_browse.html.php 43 DIRTY access::csrf_form_field() @@ -143,42 +173,51 @@ modules/gallery/views/movieplayer.html.php 7 DIRTY_JS url::a modules/gallery/views/movieplayer.html.php 13 DIRTY_JS url::abs_file("lib/flowplayer.h264streaming.swf") modules/gallery/views/permissions_browse.html.php 3 DIRTY_JS url::site("permissions/form/__ITEM__") modules/gallery/views/permissions_browse.html.php 16 DIRTY_JS url::site("permissions/change/__CMD__/__GROUP__/__PERM__/__ITEM__?csrf=$csrf") -modules/gallery/views/permissions_browse.html.php 42 DIRTY_ATTR $parent->id -modules/gallery/views/permissions_browse.html.php 44 DIRTY_JS $parent->id +modules/gallery/views/permissions_browse.html.php 43 DIRTY_ATTR $parent->id +modules/gallery/views/permissions_browse.html.php 45 DIRTY_JS $parent->id modules/gallery/views/permissions_browse.html.php 52 DIRTY_ATTR $item->id modules/gallery/views/permissions_browse.html.php 53 DIRTY_JS $item->id modules/gallery/views/permissions_browse.html.php 60 DIRTY $form -modules/gallery/views/permissions_form.html.php 24 DIRTY_JS $lock->id -modules/gallery/views/permissions_form.html.php 32 DIRTY_JS $group->id -modules/gallery/views/permissions_form.html.php 32 DIRTY_JS $permission->id -modules/gallery/views/permissions_form.html.php 32 DIRTY_JS $item->id -modules/gallery/views/permissions_form.html.php 36 DIRTY_JS $group->id -modules/gallery/views/permissions_form.html.php 36 DIRTY_JS $permission->id -modules/gallery/views/permissions_form.html.php 36 DIRTY_JS $item->id -modules/gallery/views/permissions_form.html.php 43 DIRTY_JS $group->id -modules/gallery/views/permissions_form.html.php 43 DIRTY_JS $permission->id -modules/gallery/views/permissions_form.html.php 43 DIRTY_JS $item->id -modules/gallery/views/permissions_form.html.php 47 DIRTY_JS $group->id -modules/gallery/views/permissions_form.html.php 47 DIRTY_JS $permission->id -modules/gallery/views/permissions_form.html.php 47 DIRTY_JS $item->id -modules/gallery/views/permissions_form.html.php 56 DIRTY_JS $group->id -modules/gallery/views/permissions_form.html.php 56 DIRTY_JS $permission->id -modules/gallery/views/permissions_form.html.php 56 DIRTY_JS $item->id -modules/gallery/views/permissions_form.html.php 63 DIRTY_JS $group->id -modules/gallery/views/permissions_form.html.php 63 DIRTY_JS $permission->id -modules/gallery/views/permissions_form.html.php 63 DIRTY_JS $item->id -modules/gallery/views/permissions_form.html.php 74 DIRTY_JS $group->id -modules/gallery/views/permissions_form.html.php 74 DIRTY_JS $permission->id -modules/gallery/views/permissions_form.html.php 74 DIRTY_JS $item->id -modules/gallery/views/permissions_form.html.php 79 DIRTY_JS $group->id -modules/gallery/views/permissions_form.html.php 79 DIRTY_JS $permission->id -modules/gallery/views/permissions_form.html.php 79 DIRTY_JS $item->id -modules/gallery/views/upgrader.html.php 44 DIRTY_ATTR $module->version==$module->code_version?"current":"upgradeable" -modules/gallery/views/upgrader.html.php 45 DIRTY_ATTR $id -modules/gallery/views/upgrader.html.php 49 DIRTY $module->version -modules/gallery/views/upgrader.html.php 52 DIRTY $module->code_version +modules/gallery/views/permissions_form.html.php 26 DIRTY_JS $lock->id +modules/gallery/views/permissions_form.html.php 34 DIRTY_JS $group->id +modules/gallery/views/permissions_form.html.php 34 DIRTY_JS $permission->id +modules/gallery/views/permissions_form.html.php 34 DIRTY_JS $item->id +modules/gallery/views/permissions_form.html.php 37 DIRTY_JS $group->id +modules/gallery/views/permissions_form.html.php 37 DIRTY_JS $permission->id +modules/gallery/views/permissions_form.html.php 37 DIRTY_JS $item->id +modules/gallery/views/permissions_form.html.php 44 DIRTY_JS $group->id +modules/gallery/views/permissions_form.html.php 44 DIRTY_JS $permission->id +modules/gallery/views/permissions_form.html.php 44 DIRTY_JS $item->id +modules/gallery/views/permissions_form.html.php 48 DIRTY_JS $group->id +modules/gallery/views/permissions_form.html.php 48 DIRTY_JS $permission->id +modules/gallery/views/permissions_form.html.php 48 DIRTY_JS $item->id +modules/gallery/views/permissions_form.html.php 57 DIRTY_JS $group->id +modules/gallery/views/permissions_form.html.php 57 DIRTY_JS $permission->id +modules/gallery/views/permissions_form.html.php 57 DIRTY_JS $item->id +modules/gallery/views/permissions_form.html.php 64 DIRTY_JS $group->id +modules/gallery/views/permissions_form.html.php 64 DIRTY_JS $permission->id +modules/gallery/views/permissions_form.html.php 64 DIRTY_JS $item->id +modules/gallery/views/permissions_form.html.php 75 DIRTY_JS $group->id +modules/gallery/views/permissions_form.html.php 75 DIRTY_JS $permission->id +modules/gallery/views/permissions_form.html.php 75 DIRTY_JS $item->id +modules/gallery/views/permissions_form.html.php 80 DIRTY_JS $group->id +modules/gallery/views/permissions_form.html.php 80 DIRTY_JS $permission->id +modules/gallery/views/permissions_form.html.php 80 DIRTY_JS $item->id +modules/gallery/views/simple_uploader.html.php 7 DIRTY_JS url::file("lib/uploadify/uploadify.swf") +modules/gallery/views/simple_uploader.html.php 8 DIRTY_JS url::site("simple_uploader/add_photo/{$item->id}") +modules/gallery/views/simple_uploader.html.php 15 DIRTY_JS url::file("lib/uploadify/cancel.png") +modules/gallery/views/simple_uploader.html.php 43 DIRTY_JS t("Completed") +modules/gallery/views/upgrader.html.php 57 DIRTY_ATTR $done?"muted":"" +modules/gallery/views/upgrader.html.php 61 DIRTY_ATTR $done?"muted":"" +modules/gallery/views/upgrader.html.php 69 DIRTY_ATTR $module->version==$module->code_version?"current":"upgradeable" +modules/gallery/views/upgrader.html.php 70 DIRTY_ATTR $id +modules/gallery/views/upgrader.html.php 74 DIRTY $module->version +modules/gallery/views/upgrader.html.php 77 DIRTY $module->code_version +modules/gallery/views/upgrader.html.php 99 DIRTY_ATTR $done?"muted":"" +modules/gallery/views/upgrader.html.php 102 DIRTY_ATTR $done?"muted":"" +modules/gallery/views/user_languages_block.html.php 2 DIRTY form::dropdown("g-select-session-locale",$installed_locales,$selected) modules/image_block/views/image_block_block.html.php 3 DIRTY_JS $item->url() -modules/image_block/views/image_block_block.html.php 4 DIRTY $item->thumb_img(array("class"=>"gThumbnail")) +modules/image_block/views/image_block_block.html.php 4 DIRTY $item->thumb_img(array("class"=>"g-thumbnail")) modules/info/views/info_block.html.php 22 DIRTY date("M j, Y H:i:s",$item->captured) modules/info/views/info_block.html.php 29 DIRTY_JS $item->owner->url modules/notification/views/comment_published.html.php 28 DIRTY_JS $comment->item()->abs_url() @@ -193,24 +232,24 @@ modules/organize/views/organize_dialog.html.php 3 DIRTY_JS url::s modules/organize/views/organize_dialog.html.php 4 DIRTY_JS url::site("organize/rearrange/__TARGET_ID__/__BEFORE__?csrf=$csrf") modules/organize/views/organize_dialog.html.php 5 DIRTY_JS url::site("organize/sort_order/__ALBUM_ID__/__COL__/__DIR__?csrf=$csrf") modules/organize/views/organize_dialog.html.php 6 DIRTY_JS url::site("organize/tree/__ALBUM_ID__") -modules/organize/views/organize_dialog.html.php 22 DIRTY $album_tree -modules/organize/views/organize_dialog.html.php 29 DIRTY $micro_thumb_grid -modules/organize/views/organize_dialog.html.php 37 DIRTY form::dropdown(array("id"=>"gOrganizeSortColumn"),album::get_sort_order_options(),$album->sort_column) -modules/organize/views/organize_dialog.html.php 38 DIRTY form::dropdown(array("id"=>"gOrganizeSortOrder"),array("ASC"=>"Ascending","DESC"=>"Descending"),$album->sort_order) +modules/organize/views/organize_dialog.html.php 20 DIRTY $album_tree +modules/organize/views/organize_dialog.html.php 27 DIRTY $micro_thumb_grid +modules/organize/views/organize_dialog.html.php 35 DIRTY form::dropdown(array("id"=>"g-organize-sort-column"),album::get_sort_order_options(),$album->sort_column) +modules/organize/views/organize_dialog.html.php 36 DIRTY form::dropdown(array("id"=>"g-organize-sort-order"),array("ASC"=>"Ascending","DESC"=>"Descending"),$album->sort_order) modules/organize/views/organize_thumb_grid.html.php 3 DIRTY_ATTR $child->id modules/organize/views/organize_thumb_grid.html.php 4 DIRTY_ATTR $child->id -modules/organize/views/organize_thumb_grid.html.php 5 DIRTY_ATTR $child->is_album()?"gAlbum":"gPhoto" -modules/organize/views/organize_thumb_grid.html.php 6 DIRTY $child->thumb_img(array("class"=>"gThumbnail","ref"=>$child->id),90,true) +modules/organize/views/organize_thumb_grid.html.php 5 DIRTY_ATTR $child->is_album()?"g-album":"g-photo" +modules/organize/views/organize_thumb_grid.html.php 6 DIRTY $child->thumb_img(array("class"=>"g-thumbnail","ref"=>$child->id),90,true) modules/organize/views/organize_thumb_grid.html.php 14 DIRTY_JS url::site("organize/album/$album->id/".($offset+25)) -modules/organize/views/organize_tree.html.php 2 DIRTY_ATTR access::can("edit",$album)?"":"gViewOnly" +modules/organize/views/organize_tree.html.php 2 DIRTY_ATTR access::can("edit",$album)?"":"g-view-only" modules/organize/views/organize_tree.html.php 3 DIRTY_ATTR $album->id modules/organize/views/organize_tree.html.php 6 DIRTY_ATTR $selected&&$album->id==$selected->id?"selected":"" modules/organize/views/organize_tree.html.php 7 DIRTY_ATTR $album->id modules/organize/views/organize_tree.html.php 13 DIRTY View::factory("organize_tree.html",array("selected"=>$selected,"album"=>$child)); -modules/organize/views/organize_tree.html.php 15 DIRTY_ATTR access::can("edit",$child)?"":"gViewOnly" +modules/organize/views/organize_tree.html.php 15 DIRTY_ATTR access::can("edit",$child)?"":"g-view-only" modules/organize/views/organize_tree.html.php 16 DIRTY_ATTR $child->id modules/organize/views/organize_tree.html.php 19 DIRTY_ATTR $child->id -modules/recaptcha/views/admin_recaptcha.html.php 10 DIRTY $form +modules/recaptcha/views/admin_recaptcha.html.php 11 DIRTY $form modules/recaptcha/views/admin_recaptcha.html.php 23 DIRTY_JS $public_key modules/recaptcha/views/form_recaptcha.html.php 7 DIRTY_JS $public_key modules/rss/views/feed.mrss.php 10 DIRTY $feed->uri @@ -220,14 +259,13 @@ modules/rss/views/feed.mrss.php 19 DIRTY_JS $feed- modules/rss/views/feed.mrss.php 21 DIRTY $pub_date modules/rss/views/feed.mrss.php 22 DIRTY $pub_date modules/rss/views/feed.mrss.php 28 DIRTY date("D, d M Y H:i:s T",$child->created); -modules/rss/views/feed.mrss.php 34 DIRTY_ATTR $child->resize_url(true) -modules/rss/views/feed.mrss.php 36 DIRTY_ATTR $child->resize_height -modules/rss/views/feed.mrss.php 36 DIRTY_ATTR $child->resize_width -modules/rss/views/feed.mrss.php 39 DIRTY_ATTR $child->thumb_url(true) -modules/rss/views/feed.mrss.php 41 DIRTY_ATTR $child->thumb_height -modules/rss/views/feed.mrss.php 41 DIRTY_ATTR $child->thumb_width -modules/rss/views/feed.mrss.php 47 DIRTY_ATTR $child->thumb_url(true) -modules/rss/views/feed.mrss.php 48 DIRTY_ATTR @filesize($child->thumb_path()) +modules/rss/views/feed.mrss.php 35 DIRTY_ATTR $child->resize_url(true) +modules/rss/views/feed.mrss.php 37 DIRTY_ATTR $child->resize_height +modules/rss/views/feed.mrss.php 37 DIRTY_ATTR $child->resize_width +modules/rss/views/feed.mrss.php 40 DIRTY_ATTR $child->thumb_url(true) +modules/rss/views/feed.mrss.php 42 DIRTY_ATTR $child->thumb_height +modules/rss/views/feed.mrss.php 42 DIRTY_ATTR $child->thumb_width +modules/rss/views/feed.mrss.php 48 DIRTY_ATTR $child->thumb_url(true) modules/rss/views/feed.mrss.php 49 DIRTY_ATTR $child->thumb_height modules/rss/views/feed.mrss.php 50 DIRTY_ATTR $child->thumb_width modules/rss/views/feed.mrss.php 54 DIRTY_ATTR $child->resize_url(true) @@ -249,99 +287,98 @@ modules/rss/views/rss_block.html.php 6 DIRTY_JS rss::u modules/search/views/search.html.php 30 DIRTY_ATTR $item_class modules/search/views/search.html.php 31 DIRTY_JS $item->url() modules/search/views/search.html.php 32 DIRTY $item->thumb_img() +modules/search/views/search.html.php 43 DIRTY $theme->paginator() +modules/server_add/views/admin_server_add.html.php 5 DIRTY $form modules/server_add/views/admin_server_add.html.php 15 DIRTY_ATTR $id -modules/server_add/views/admin_server_add.html.php 24 DIRTY $form modules/server_add/views/server_add_tree.html.php 20 DIRTY_ATTR is_dir($file)?"ui-icon-folder-collapsed":"ui-icon-document" -modules/server_add/views/server_add_tree.html.php 21 DIRTY_ATTR is_dir($file)?"gDirectory":"gFile" +modules/server_add/views/server_add_tree.html.php 21 DIRTY_ATTR is_dir($file)?"g-directory":"g-file" modules/server_add/views/server_add_tree_dialog.html.php 3 DIRTY_JS url::site("server_add/children?path=__PATH__") modules/server_add/views/server_add_tree_dialog.html.php 4 DIRTY_JS url::site("server_add/start?item_id={$item->id}&csrf=$csrf") -modules/server_add/views/server_add_tree_dialog.html.php 23 DIRTY $tree -modules/tag/views/admin_tags.html.php 13 DIRTY_JS $csrf -modules/tag/views/admin_tags.html.php 50 DIRTY_ATTR $tag->id -modules/tag/views/admin_tags.html.php 51 DIRTY $tag->count -modules/tag/views/tag_block.html.php 15 DIRTY $cloud -modules/tag/views/tag_block.html.php 17 DIRTY $form +modules/server_add/views/server_add_tree_dialog.html.php 21 DIRTY $tree +modules/tag/views/admin_tags.html.php 45 DIRTY_ATTR $tag->id +modules/tag/views/admin_tags.html.php 46 DIRTY $tag->count +modules/tag/views/tag_block.html.php 27 DIRTY $cloud +modules/tag/views/tag_block.html.php 29 DIRTY $form modules/tag/views/tag_cloud.html.php 4 DIRTY_ATTR (int)(($tag->count/$max_count)*7) modules/tag/views/tag_cloud.html.php 5 DIRTY $tag->count +modules/tag/views/tag_cloud.html.php 6 DIRTY_JS $tag->url() modules/user/views/admin_users.html.php 3 DIRTY_JS url::site("admin/users/add_user_to_group/__USERID__/__GROUPID__?csrf=$csrf") modules/user/views/admin_users.html.php 26 DIRTY_JS url::site("admin/users/group/__GROUPID__") modules/user/views/admin_users.html.php 36 DIRTY_JS url::site("admin/users/remove_user_from_group/__USERID__/__GROUPID__?csrf=$csrf") -modules/user/views/admin_users.html.php 67 DIRTY_ATTR $user->id -modules/user/views/admin_users.html.php 67 DIRTY_ATTR text::alternate("gOddRow","gEvenRow") -modules/user/views/admin_users.html.php 67 DIRTY_ATTR $user->admin?"admin":"" -modules/user/views/admin_users.html.php 68 DIRTY_ATTR $user->id -modules/user/views/admin_users.html.php 69 DIRTY_ATTR $user->avatar_url(20,$theme->url(,true)) -modules/user/views/admin_users.html.php 83 DIRTY ($user->last_login==0)?"":gallery::date($user->last_login) -modules/user/views/admin_users.html.php 121 DIRTY_ATTR $group->id -modules/user/views/admin_users.html.php 121 DIRTY_ATTR ($group->special?"gDefaultGroup":"") -modules/user/views/admin_users.html.php 123 DIRTY $v +modules/user/views/admin_users.html.php 71 DIRTY_ATTR $user->id +modules/user/views/admin_users.html.php 71 DIRTY_ATTR text::alternate("g-odd","g-even") +modules/user/views/admin_users.html.php 71 DIRTY_ATTR $user->admin?"g-admin":"" +modules/user/views/admin_users.html.php 72 DIRTY_ATTR $user->id +modules/user/views/admin_users.html.php 73 DIRTY_ATTR $user->avatar_url(20,$theme->url(,true)) +modules/user/views/admin_users.html.php 87 DIRTY ($user->last_login==0)?"":gallery::date($user->last_login) +modules/user/views/admin_users.html.php 123 DIRTY_ATTR $group->id +modules/user/views/admin_users.html.php 123 DIRTY_ATTR ($group->special?"g-default-group":"") +modules/user/views/admin_users.html.php 125 DIRTY $v modules/user/views/admin_users_group.html.php 22 DIRTY_JS $user->id modules/user/views/admin_users_group.html.php 22 DIRTY_JS $group->id -modules/user/views/login_ajax.html.php 6 DIRTY_JS url::site("password/reset") -modules/user/views/login_ajax.html.php 37 DIRTY $form -modules/user/views/user_languages_block.html.php 2 DIRTY form::dropdown("gSelectSessionLocale",$installed_locales,$selected) -modules/watermark/views/admin_watermarks.html.php 19 DIRTY_ATTR $width -modules/watermark/views/admin_watermarks.html.php 19 DIRTY_ATTR $height -modules/watermark/views/admin_watermarks.html.php 19 DIRTY_ATTR $url -themes/admin_default/views/admin.html.php 15 DIRTY_JS $theme->url() -themes/admin_default/views/admin.html.php 32 DIRTY $theme->admin_head() -themes/admin_default/views/admin.html.php 36 DIRTY $theme->admin_page_top() -themes/admin_default/views/admin.html.php 44 DIRTY $theme->admin_header_top() -themes/admin_default/views/admin.html.php 49 DIRTY_JS item::root()->url() -themes/admin_default/views/admin.html.php 53 DIRTY $theme->admin_menu() -themes/admin_default/views/admin.html.php 55 DIRTY $theme->admin_header_bottom() -themes/admin_default/views/admin.html.php 62 DIRTY $content -themes/admin_default/views/admin.html.php 68 DIRTY $sidebar -themes/admin_default/views/admin.html.php 73 DIRTY $theme->admin_footer() -themes/admin_default/views/admin.html.php 75 DIRTY $theme->admin_credits() -themes/admin_default/views/admin.html.php 79 DIRTY $theme->admin_page_bottom() -themes/admin_default/views/block.html.php 3 DIRTY_ATTR $anchor -themes/admin_default/views/block.html.php 5 DIRTY $id -themes/admin_default/views/block.html.php 5 DIRTY_ATTR $css_id -themes/admin_default/views/block.html.php 13 DIRTY $title -themes/admin_default/views/block.html.php 16 DIRTY $content -themes/admin_default/views/pager.html.php 13 DIRTY_JS str_replace('{page}',1,$url) -themes/admin_default/views/pager.html.php 20 DIRTY_JS str_replace('{page}',$previous_page,$url) -themes/admin_default/views/pager.html.php 27 DIRTY $from_to_msg -themes/admin_default/views/pager.html.php 30 DIRTY_JS str_replace('{page}',$next_page,$url) -themes/admin_default/views/pager.html.php 37 DIRTY_JS str_replace('{page}',$last_page,$url) -themes/default/views/album.html.php 16 DIRTY_ATTR $child->id -themes/default/views/album.html.php 16 DIRTY_ATTR $item_class -themes/default/views/album.html.php 18 DIRTY_JS $child->url() -themes/default/views/album.html.php 19 DIRTY $child->thumb_img(array("class"=>"gThumbnail")) -themes/default/views/album.html.php 23 DIRTY_JS $child->url() -themes/default/views/block.html.php 3 DIRTY_ATTR $anchor -themes/default/views/block.html.php 5 DIRTY_ATTR $css_id -themes/default/views/block.html.php 6 DIRTY $title -themes/default/views/block.html.php 8 DIRTY $content -themes/default/views/dynamic.html.php 11 DIRTY_ATTR $child->is_album()?"gAlbum":"" -themes/default/views/dynamic.html.php 13 DIRTY_JS $child->url() -themes/default/views/dynamic.html.php 14 DIRTY_ATTR $child->id -themes/default/views/dynamic.html.php 15 DIRTY_ATTR $child->thumb_url() -themes/default/views/dynamic.html.php 16 DIRTY_ATTR $child->thumb_width -themes/default/views/dynamic.html.php 17 DIRTY_ATTR $child->thumb_height -themes/default/views/movie.html.php 8 DIRTY_JS $previous_item->url() -themes/default/views/movie.html.php 18 DIRTY_JS $next_item->url() -themes/default/views/movie.html.php 28 DIRTY $item->movie_img(array("class"=>"gMovie","id"=>"gMovieId-{$item->id}")) -themes/default/views/page.html.php 9 DIRTY $page_title -themes/default/views/page.html.php 32 DIRTY_JS $theme->url() -themes/default/views/page.html.php 41 DIRTY $new_width -themes/default/views/page.html.php 42 DIRTY $new_height -themes/default/views/page.html.php 43 DIRTY $thumb_proportion -themes/default/views/page.html.php 82 DIRTY $header_text -themes/default/views/page.html.php 84 DIRTY_JS item::root()->url() -themes/default/views/page.html.php 102 DIRTY_JS $parent->url($parent==$theme->item()->parent()?"show={$theme->item()->id}":null) -themes/default/views/page.html.php 117 DIRTY $content -themes/default/views/page.html.php 123 DIRTY newView("sidebar.html") -themes/default/views/page.html.php 130 DIRTY $footer_text -themes/default/views/pager.html.php 13 DIRTY_JS str_replace('{page}',1,$url) -themes/default/views/pager.html.php 20 DIRTY_JS str_replace('{page}',$previous_page,$url) -themes/default/views/pager.html.php 27 DIRTY $from_to_msg -themes/default/views/pager.html.php 30 DIRTY_JS str_replace('{page}',$next_page,$url) -themes/default/views/pager.html.php 37 DIRTY_JS str_replace('{page}',$last_page,$url) -themes/default/views/photo.html.php 8 DIRTY_JS $theme->item()->width -themes/default/views/photo.html.php 8 DIRTY_JS $theme->item()->height -themes/default/views/photo.html.php 21 DIRTY_JS $previous_item->url() -themes/default/views/photo.html.php 31 DIRTY_JS $next_item->url() -themes/default/views/photo.html.php 43 DIRTY_JS $item->file_url() -themes/default/views/photo.html.php 45 DIRTY $item->resize_img(array("id"=>"gPhotoId-{$item->id}","class"=>"gResize")) +modules/user/views/user_form.html.php 7 DIRTY $form +modules/watermark/views/admin_watermarks.html.php 20 DIRTY_ATTR $width +modules/watermark/views/admin_watermarks.html.php 20 DIRTY_ATTR $height +modules/watermark/views/admin_watermarks.html.php 20 DIRTY_ATTR $url +themes/admin_wind/views/admin.html.php 16 DIRTY_JS $theme->url() +themes/admin_wind/views/admin.html.php 33 DIRTY $theme->admin_head() +themes/admin_wind/views/admin.html.php 37 DIRTY $theme->admin_page_top() +themes/admin_wind/views/admin.html.php 45 DIRTY $theme->admin_header_top() +themes/admin_wind/views/admin.html.php 60 DIRTY_JS item::root()->url() +themes/admin_wind/views/admin.html.php 64 DIRTY $theme->admin_menu() +themes/admin_wind/views/admin.html.php 66 DIRTY $theme->admin_header_bottom() +themes/admin_wind/views/admin.html.php 73 DIRTY $content +themes/admin_wind/views/admin.html.php 79 DIRTY $sidebar +themes/admin_wind/views/admin.html.php 84 DIRTY $theme->admin_footer() +themes/admin_wind/views/admin.html.php 86 DIRTY $theme->admin_credits() +themes/admin_wind/views/admin.html.php 90 DIRTY $theme->admin_page_bottom() +themes/admin_wind/views/block.html.php 3 DIRTY_ATTR $anchor +themes/admin_wind/views/block.html.php 5 DIRTY $id +themes/admin_wind/views/block.html.php 5 DIRTY_ATTR $css_id +themes/admin_wind/views/block.html.php 13 DIRTY $title +themes/admin_wind/views/block.html.php 16 DIRTY $content +themes/admin_wind/views/pager.html.php 13 DIRTY_JS str_replace('{page}',1,$url) +themes/admin_wind/views/pager.html.php 20 DIRTY_JS str_replace('{page}',$previous_page,$url) +themes/admin_wind/views/pager.html.php 27 DIRTY $from_to_msg +themes/admin_wind/views/pager.html.php 30 DIRTY_JS str_replace('{page}',$next_page,$url) +themes/admin_wind/views/pager.html.php 37 DIRTY_JS str_replace('{page}',$last_page,$url) +themes/wind/views/album.html.php 16 DIRTY_ATTR $child->id +themes/wind/views/album.html.php 16 DIRTY_ATTR $item_class +themes/wind/views/album.html.php 18 DIRTY_JS $child->url() +themes/wind/views/album.html.php 19 DIRTY $child->thumb_img(array("class"=>"g-thumbnail")) +themes/wind/views/album.html.php 23 DIRTY_JS $child->url() +themes/wind/views/album.html.php 41 DIRTY $theme->paginator() +themes/wind/views/block.html.php 3 DIRTY_ATTR $anchor +themes/wind/views/block.html.php 5 DIRTY_ATTR $css_id +themes/wind/views/block.html.php 6 DIRTY $title +themes/wind/views/block.html.php 8 DIRTY $content +themes/wind/views/dynamic.html.php 11 DIRTY_ATTR $child->is_album()?"g-album":"" +themes/wind/views/dynamic.html.php 13 DIRTY_JS $child->url() +themes/wind/views/dynamic.html.php 14 DIRTY_ATTR $child->id +themes/wind/views/dynamic.html.php 15 DIRTY_ATTR $child->thumb_url() +themes/wind/views/dynamic.html.php 16 DIRTY_ATTR $child->thumb_width +themes/wind/views/dynamic.html.php 17 DIRTY_ATTR $child->thumb_height +themes/wind/views/dynamic.html.php 29 DIRTY $theme->paginator() +themes/wind/views/movie.html.php 5 DIRTY $theme->paginator() +themes/wind/views/movie.html.php 8 DIRTY $item->movie_img(array("class"=>"g-movie","id"=>"g-movie-id-{$item->id}")) +themes/wind/views/page.html.php 9 DIRTY $page_title +themes/wind/views/page.html.php 33 DIRTY_JS $theme->url() +themes/wind/views/page.html.php 42 DIRTY $new_width +themes/wind/views/page.html.php 43 DIRTY $new_height +themes/wind/views/page.html.php 44 DIRTY $thumb_proportion +themes/wind/views/page.html.php 81 DIRTY $header_text +themes/wind/views/page.html.php 83 DIRTY_JS item::root()->url() +themes/wind/views/page.html.php 87 DIRTY $theme->user_menu() +themes/wind/views/page.html.php 104 DIRTY_JS $parent->url($parent==$theme->item()->parent()?"show={$theme->item()->id}":null) +themes/wind/views/page.html.php 120 DIRTY $content +themes/wind/views/page.html.php 126 DIRTY newView("sidebar.html") +themes/wind/views/page.html.php 133 DIRTY $footer_text +themes/wind/views/paginator.html.php 32 DIRTY_JS $first_page_url +themes/wind/views/paginator.html.php 41 DIRTY_JS $previous_page_url +themes/wind/views/paginator.html.php 69 DIRTY_JS $next_page_url +themes/wind/views/paginator.html.php 78 DIRTY_JS $last_page_url +themes/wind/views/photo.html.php 8 DIRTY_JS $theme->item()->width +themes/wind/views/photo.html.php 8 DIRTY_JS $theme->item()->height +themes/wind/views/photo.html.php 18 DIRTY $theme->paginator() +themes/wind/views/photo.html.php 23 DIRTY_JS $item->file_url() +themes/wind/views/photo.html.php 25 DIRTY $item->resize_img(array("id"=>"g-photo-id-{$item->id}","class"=>"g-resize")) |