diff options
-rw-r--r-- | modules/block.module | 8 | ||||
-rw-r--r-- | modules/block/block.module | 8 | ||||
-rw-r--r-- | modules/user.module | 2 | ||||
-rw-r--r-- | modules/user/user.module | 2 |
4 files changed, 18 insertions, 2 deletions
diff --git a/modules/block.module b/modules/block.module index 9b9d64ee2..60ea18e96 100644 --- a/modules/block.module +++ b/modules/block.module @@ -248,6 +248,14 @@ function block_admin() { function block_user($type, &$edit, &$user) { switch ($type) { + case "register_form": + $result = db_query("SELECT * FROM blocks WHERE custom = '%d' ORDER BY name", 1); + + while ($block = db_fetch_object($result)) { + $form .= form_hidden("block][$block->name", $block->status); + } + + return $form; case "edit_form": $result = db_query("SELECT * FROM blocks WHERE custom = '%d' ORDER BY name", 1); diff --git a/modules/block/block.module b/modules/block/block.module index 9b9d64ee2..60ea18e96 100644 --- a/modules/block/block.module +++ b/modules/block/block.module @@ -248,6 +248,14 @@ function block_admin() { function block_user($type, &$edit, &$user) { switch ($type) { + case "register_form": + $result = db_query("SELECT * FROM blocks WHERE custom = '%d' ORDER BY name", 1); + + while ($block = db_fetch_object($result)) { + $form .= form_hidden("block][$block->name", $block->status); + } + + return $form; case "edit_form": $result = db_query("SELECT * FROM blocks WHERE custom = '%d' ORDER BY name", 1); diff --git a/modules/user.module b/modules/user.module index b3815ee30..df8dbe316 100644 --- a/modules/user.module +++ b/modules/user.module @@ -480,7 +480,7 @@ function user_block() { $output .= "<input name=\"edit[remember_me]\" type=\"checkbox\" />". t("Remember me") ."<br />\n"; $output .= "<input name=\"edit[op]\" type=\"submit\" value=\"". t("Log in") ."\" /><br />\n"; $output .= "</form></div>\n"; - if (variable_get("account_register", 1)) { + if (variable_get("user_register", 1)) { $output .= "» ". lm(t("Register"), array("mod" => "user", "op" => "register"), t("Create a new user account.")) ."\n"; } $output .= "<br />» ". lm(t("New password"), array("mod" => "user", "op" => "password"), t("Request new password via e-mail")) ."<br />"; diff --git a/modules/user/user.module b/modules/user/user.module index b3815ee30..df8dbe316 100644 --- a/modules/user/user.module +++ b/modules/user/user.module @@ -480,7 +480,7 @@ function user_block() { $output .= "<input name=\"edit[remember_me]\" type=\"checkbox\" />". t("Remember me") ."<br />\n"; $output .= "<input name=\"edit[op]\" type=\"submit\" value=\"". t("Log in") ."\" /><br />\n"; $output .= "</form></div>\n"; - if (variable_get("account_register", 1)) { + if (variable_get("user_register", 1)) { $output .= "» ". lm(t("Register"), array("mod" => "user", "op" => "register"), t("Create a new user account.")) ."\n"; } $output .= "<br />» ". lm(t("New password"), array("mod" => "user", "op" => "password"), t("Request new password via e-mail")) ."<br />"; |