From cc381c14613b4c4539d74f38ec58196f6dfcdaa0 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Fri, 1 Nov 2002 10:47:20 +0000 Subject: - Fixed glitch in block module: the admin links were not composed correctly. Patch by Stefan. - Added missing t() functions and improved the %x directives for better readability and to ease the process of translating your site. Patches by Stefan. - Made two small additions to the 'code-clean.sh' script; it will now remove patch related junk. NOTES: - I removed the · related bits. Let's tackle these later on in a separate patch after we got some sort of consensus. - I removed the 'module_exist("drupal")' check in the user module; I *think* it is incomplete and therefore incorrect. - Stefan, try using quotes in your translations and check whether everything still works. Example: translate the "Create account" button to "Create \"haha\" account \'hihi\'" and see if you can still create new accounts. Maybe automate this using a quick hack in the locale module ... --- modules/block.module | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'modules/block.module') diff --git a/modules/block.module b/modules/block.module index 0f4945256..12d42e42e 100644 --- a/modules/block.module +++ b/modules/block.module @@ -81,7 +81,7 @@ function block_admin_save($edit) { /** * update blocks db table with blocks currently exported by modules - * + * * @param array $order_by php array_multisort() style sort ordering, eg. "weight", SORT_ASC, SORT_STRING. see {@link http://www.php.net/manual/en/function.array-multisort.php} * @return array blocks currently exported by modules, sorted by $order_by * @access private @@ -116,7 +116,7 @@ function _block_rehash($order_by = array("weight")) { db_query("INSERT INTO blocks (module, delta, status, weight, region, path, custom) VALUES ('%s', '%d', '%d', '%d', '%d', '%s', '%d')", $block["module"], $block["delta"], $block["status"], $block["weight"], $block["region"], $block["path"], $block["custom"]); $blocks[] = $block; - + // build array to sort on $order[$order_by[0]][] = $block[$order_by[0]]; } @@ -139,7 +139,7 @@ function block_admin_display() { foreach ($blocks as $block) { $output .= ""; $output .= "".$block["info"].""; - $output .= "". (module_hook($block["module"], "admin") ? la($block["module"], array("mod" => $module), "", array("title" => t("Administer module"))) : $block["module"]) .""; + $output .= "". (module_hook($block["module"], "admin") ? la($block["module"], array("mod" => $block["module"]), "", array("title" => t("Administer module"))) : $block["module"]) .""; $output .= "". form_checkbox(NULL, $block["module"]."][".$block["delta"]."][status", 1, $block["status"]) .""; $output .= "". form_checkbox(NULL, $block["module"]."][".$block["delta"]."][custom", 1, $block["custom"]) .""; $output .= "". form_weight(NULL, $block["module"]."][".$block["delta"]."][weight", $block["weight"]) .""; -- cgit v1.2.3