parent
3d3a60740a
commit
e90f3b883b
|
@ -664,10 +664,10 @@ function format_date($timestamp, $type = "medium", $format = "") {
|
|||
$date = date(variable_get("date_format", "m/d/Y - H:i"), $timestamp);
|
||||
break;
|
||||
case "medium":
|
||||
$date = t(date("l", $timestamp)) .", ". date(variable_get("date_format", "m/d/Y - H:i"), $timestamp);
|
||||
$date = date(variable_get("date_format_medium", "D, m/d/Y - H:i"), $timestamp);
|
||||
break;
|
||||
case "large":
|
||||
$date = t(date("l", $timestamp)) .", ". t(date("F", $timestamp)) ." ". date("d, Y - H:i", $timestamp);
|
||||
$date = date(variable_get("date_format_long", "l, F j, Y - H:i"), $timestamp);
|
||||
break;
|
||||
case "custom":
|
||||
for ($i = strlen($format); $i >= 0; $c = $format[--$i]) {
|
||||
|
@ -683,7 +683,7 @@ function format_date($timestamp, $type = "medium", $format = "") {
|
|||
}
|
||||
break;
|
||||
default:
|
||||
$date = t(date("l", $timestamp)) .", ". date(variable_get("date_format", "m/d/Y - H:i"), $timestamp);
|
||||
$date = date(variable_get("date_format_medium", "l, m/d/Y - H:i"), $timestamp);
|
||||
}
|
||||
return $date;
|
||||
}
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
* @return string html of pager
|
||||
*/
|
||||
function pager_display($tags = "", $limit = 10, $element = 0, $type = "default", $attributes = array()) {
|
||||
return theme_invoke("pager_display_". $type, $tags, $limit, $element, $attributes = array());
|
||||
return theme("pager_display_". $type, $tags, $limit, $element, $attributes = array());
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -169,13 +169,13 @@ function theme_blocks($region) {
|
|||
if ((($block->status && (!$user->uid || !$block->custom)) || ($block->custom && $user->block[$block->module][$block->delta])) && (!$block->path || preg_match("|$block->path|", $PHP_SELF))) {
|
||||
$block_data = module_invoke($block->module, "block", "view", $block->delta);
|
||||
if ($block_data["content"]) {
|
||||
theme_invoke("block", $block_data["subject"], $block_data["content"], $region);
|
||||
theme("block", $block_data["subject"], $block_data["content"], $region);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function theme_invoke() {
|
||||
function theme() {
|
||||
global $theme;
|
||||
$args = func_get_args();
|
||||
|
||||
|
|
|
@ -16,7 +16,7 @@ function import_system($field){
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function import_conf_options() {
|
||||
function import_settings() {
|
||||
$number = array(5 => 5, 10 => 10, 15 => 15, 20 => 20, 25 => 25, 30 => 30, 35 => 35, 40 => 40, 45 => 45, 50 => 50, 55 => 55, 60 => 60, 65 => 65, 70 => 70, 75 => 75, 80 => 80, 85 => 85, 90 => 90, 95 => 95, 100 => 100);
|
||||
$output .= form_select("Items per block", "import_block_limit", variable_get("import_block_limit", 15), $number, "The maximum number of news items displayed in one block.");
|
||||
$output .= form_select("Items per page", "import_page_limit", variable_get("import_page_limit", 75), $number, "The maximum number of news items displayed on one page.");
|
||||
|
|
|
@ -16,7 +16,7 @@ function import_system($field){
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function import_conf_options() {
|
||||
function import_settings() {
|
||||
$number = array(5 => 5, 10 => 10, 15 => 15, 20 => 20, 25 => 25, 30 => 30, 35 => 35, 40 => 40, 45 => 45, 50 => 50, 55 => 55, 60 => 60, 65 => 65, 70 => 70, 75 => 75, 80 => 80, 85 => 85, 90 => 90, 95 => 95, 100 => 100);
|
||||
$output .= form_select("Items per block", "import_block_limit", variable_get("import_block_limit", 15), $number, "The maximum number of news items displayed in one block.");
|
||||
$output .= form_select("Items per page", "import_page_limit", variable_get("import_page_limit", 75), $number, "The maximum number of news items displayed on one page.");
|
||||
|
|
|
@ -188,7 +188,7 @@ function archive_page() {
|
|||
$theme->footer();
|
||||
}
|
||||
|
||||
function archive_conf_options() {
|
||||
function archive_settings() {
|
||||
|
||||
$output .= form_select( t("First day of week"), "default_firstday", variable_get("default_firstday", 0), array(0 => t("Sunday"), 1 => t("Monday"), 2 => t("Tuesday"), 3 => t("Wednesday"), 4 => t("Thursday"), 5 => t("Friday"), 6 => t("Saturday")), t("The first day of the week. By changing this value you choose how the calendar block is rendered."));
|
||||
|
||||
|
|
|
@ -188,7 +188,7 @@ function archive_page() {
|
|||
$theme->footer();
|
||||
}
|
||||
|
||||
function archive_conf_options() {
|
||||
function archive_settings() {
|
||||
|
||||
$output .= form_select( t("First day of week"), "default_firstday", variable_get("default_firstday", 0), array(0 => t("Sunday"), 1 => t("Monday"), 2 => t("Tuesday"), 3 => t("Wednesday"), 4 => t("Thursday"), 5 => t("Friday"), 6 => t("Saturday")), t("The first day of the week. By changing this value you choose how the calendar block is rendered."));
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ function blog_system($field){
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function blog_conf_options() {
|
||||
function blog_settings() {
|
||||
$output = form_textarea(t("Explanation or submission guidelines"), "blog_help", variable_get("blog_help", ""), 55, 4, t("This text is displayed at the top of the blog submission form. It's useful for helping or instructing your users."));
|
||||
$words = t("words");
|
||||
$output .= form_select(t("Minimum number of words in a blog entry"), "minimum_blog_size", variable_get("minimum_blog_size", 0), array(0 => "0 $words", 10 => "10 $words", 25 => "25 $words", 50 => "50 $words", 75 => "75 $words", 100 => "100 $words", 125 => "125 $words", 150 => "150 $words", 175 => "175 $words", 200 => "200 $words"), t("The minimum number of words a personal blog entry should contain. This is useful to rule out submissions that do not meet the site's standards, such as short test posts."));
|
||||
|
@ -185,7 +185,7 @@ function blog_form(&$node, &$help, &$error) {
|
|||
*/
|
||||
|
||||
if (count(explode(" ", $node->body)) < variable_get("minimum_blog_size", 0)) {
|
||||
$error["body"] = theme_invoke("theme_error", t("The body of your blog is too short."));
|
||||
$error["body"] = theme("theme_error", t("The body of your blog is too short."));
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -6,7 +6,7 @@ function blog_system($field){
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function blog_conf_options() {
|
||||
function blog_settings() {
|
||||
$output = form_textarea(t("Explanation or submission guidelines"), "blog_help", variable_get("blog_help", ""), 55, 4, t("This text is displayed at the top of the blog submission form. It's useful for helping or instructing your users."));
|
||||
$words = t("words");
|
||||
$output .= form_select(t("Minimum number of words in a blog entry"), "minimum_blog_size", variable_get("minimum_blog_size", 0), array(0 => "0 $words", 10 => "10 $words", 25 => "25 $words", 50 => "50 $words", 75 => "75 $words", 100 => "100 $words", 125 => "125 $words", 150 => "150 $words", 175 => "175 $words", 200 => "200 $words"), t("The minimum number of words a personal blog entry should contain. This is useful to rule out submissions that do not meet the site's standards, such as short test posts."));
|
||||
|
@ -185,7 +185,7 @@ function blog_form(&$node, &$help, &$error) {
|
|||
*/
|
||||
|
||||
if (count(explode(" ", $node->body)) < variable_get("minimum_blog_size", 0)) {
|
||||
$error["body"] = theme_invoke("theme_error", t("The body of your blog is too short."));
|
||||
$error["body"] = theme("theme_error", t("The body of your blog is too short."));
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -20,7 +20,7 @@ function comment_system($field) {
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function comment_conf_options() {
|
||||
function comment_settings() {
|
||||
global $cmodes, $corder;
|
||||
|
||||
$output .= form_select(t("Default display mode"), "comment_default_mode", variable_get("comment_default_mode", 4), $cmodes, t("The default view for comments. Expanded views display the body of the comment. Threaded views keep replies together."));
|
||||
|
@ -340,7 +340,7 @@ function comment_links($comment, $return = 1) {
|
|||
$links[] = l(t("reply to this comment"), "comment/reply/$comment->nid/$comment->cid");
|
||||
}
|
||||
else {
|
||||
$links[] = theme_invoke("comment_post_forbidden");
|
||||
$links[] = theme("comment_post_forbidden");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -365,10 +365,10 @@ function comment_view($comment, $links = "", $visible = 1) {
|
|||
print "<a name=\"$comment->cid\"></a>\n";
|
||||
|
||||
if ($visible) {
|
||||
theme_invoke("comment", $comment, $links);
|
||||
theme("comment", $comment, $links);
|
||||
}
|
||||
else {
|
||||
theme_invoke("comment_folded", $comment);
|
||||
theme("comment_folded", $comment);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -458,7 +458,7 @@ function comment_render($node, $cid = 0) {
|
|||
|
||||
if ($comment_num && ((variable_get("comment_controls", 0) == 0) || (variable_get("comment_controls", 0) == 2))) {
|
||||
print "<form method=\"post\" action=\"". url("comment") ."\">\n";
|
||||
$theme->box(t("Control panel"), theme_invoke("comment_controls", $threshold, $mode, $order, $nid, $comment_page, $comment_num, $comments_per_page));
|
||||
$theme->box(t("Control panel"), theme("comment_controls", $threshold, $mode, $order, $nid, $comment_page, $comment_num, $comments_per_page));
|
||||
print form_hidden("nid", $nid);
|
||||
print "</form>";
|
||||
}
|
||||
|
@ -475,7 +475,7 @@ function comment_render($node, $cid = 0) {
|
|||
while ($comment = db_fetch_object($result)) {
|
||||
$comments[$comment->cid] = $comment;
|
||||
}
|
||||
theme_invoke("comment_flat_collapsed", $comments, $threshold_min);
|
||||
theme("comment_flat_collapsed", $comments, $threshold_min);
|
||||
}
|
||||
else if ($mode == 2) {
|
||||
/*
|
||||
|
@ -515,7 +515,7 @@ function comment_render($node, $cid = 0) {
|
|||
}
|
||||
}
|
||||
|
||||
theme_invoke("comment_flat_expanded", $comments, $threshold_min);
|
||||
theme("comment_flat_expanded", $comments, $threshold_min);
|
||||
|
||||
if (comment_user_can_moderate($node) && $show_moderate_button) {
|
||||
print "<div align=\"center\">". form_submit(t("Moderate comments")) ."</div><br />";
|
||||
|
@ -530,7 +530,7 @@ function comment_render($node, $cid = 0) {
|
|||
$comments[$comment->cid] = $comment;
|
||||
}
|
||||
if ($comments) {
|
||||
theme_invoke("comment_thread_min", $comments, $threshold_min);
|
||||
theme("comment_thread_min", $comments, $threshold_min);
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
@ -556,7 +556,7 @@ function comment_render($node, $cid = 0) {
|
|||
$page = 1;
|
||||
foreach ($structure as $cid => $depth) {
|
||||
if ($page == $comment_page) {
|
||||
theme_invoke("comment_thread_max", $comments[$cid], $threshold_min, $depth - 1);
|
||||
theme("comment_thread_max", $comments[$cid], $threshold_min, $depth - 1);
|
||||
}
|
||||
$comment_num++;
|
||||
if ($comment_num == $comments_per_page) {
|
||||
|
@ -580,7 +580,7 @@ function comment_render($node, $cid = 0) {
|
|||
|
||||
if ($comment_num && ((variable_get("comment_controls", 0) == 1) || (variable_get("comment_controls", 0) == 2))) {
|
||||
print "<form method=\"post\" action=\"". url("comment") ."\">\n";
|
||||
$theme->box(t("Control panel"), theme_invoke("comment_controls", $threshold, $mode, $order, $nid, $comment_page, $comment_num, $comments_per_page));
|
||||
$theme->box(t("Control panel"), theme("comment_controls", $threshold, $mode, $order, $nid, $comment_page, $comment_num, $comments_per_page));
|
||||
print form_hidden("nid", $nid);
|
||||
print "</form>";
|
||||
}
|
||||
|
@ -632,7 +632,7 @@ function comment_link($type, $node = 0, $main = 0) {
|
|||
$links[] = l(t("add new comment"), "comment/reply/$node->nid", array("title" => t("Add a new comment to this page.")));
|
||||
}
|
||||
else {
|
||||
$links[] = theme_invoke("comment_post_forbidden");
|
||||
$links[] = theme("comment_post_forbidden");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -648,7 +648,7 @@ function comment_link($type, $node = 0, $main = 0) {
|
|||
$links[] = l(t("add new comment"), "comment/reply/$node->nid", array("title" => t("Share your thoughts and opinions related to this posting.")));
|
||||
}
|
||||
else {
|
||||
$links[] = theme_invoke("comment_post_forbidden");
|
||||
$links[] = theme("comment_post_forbidden");
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
@ -717,9 +717,9 @@ function comment_page() {
|
|||
drupal_goto(url("node/view/". $edit["nid"]));
|
||||
}
|
||||
break;
|
||||
case t("Update settings"):
|
||||
case t("Save settings"):
|
||||
global $mode, $order, $threshold, $comments_per_page;
|
||||
comment_settings(check_query($mode), check_query($order), check_query($threshold), check_query($comments_per_page));
|
||||
comment_save_settings(check_query($mode), check_query($order), check_query($threshold), check_query($comments_per_page));
|
||||
drupal_goto(url("node/view/". $edit["nid"], "mode=$mode&order=$order&threshold=$threshold&comments_per_page=$comments_per_page"));
|
||||
break;
|
||||
}
|
||||
|
@ -1107,9 +1107,9 @@ function comment_controls($threshold = 1, $mode = 3, $order = 1, $nid, $page = 0
|
|||
$output .= comment_per_page_form($comments_per_page);
|
||||
$output .= comment_threshold($threshold);
|
||||
|
||||
$output .= " ". form_submit(t("Update settings"));
|
||||
$output .= " ". form_submit(t("Save settings"));
|
||||
|
||||
$output = form_item(t("Comment viewing options"), $output, t("Select your preferred way to display the comments and click 'Update settings' to submit your changes."));
|
||||
$output = form_item(t("Comment viewing options"), $output, t("Select your preferred way to display the comments and click 'Save settings' to submit your changes."));
|
||||
|
||||
if (($mode == 2 || $mode == 4) && $comment_num > $comments_per_page) {
|
||||
if ($page > 1) {
|
||||
|
@ -1165,7 +1165,7 @@ function comment_moderation_form($comment) {
|
|||
function comment($comment, $link = 0) {
|
||||
$output .= "<div style=\"border: 1px solid; padding: 10px;\">";
|
||||
$output .= "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\">";
|
||||
$output .= " <tr><td><div style=\"font-size: 110%; font-weight: bold;\">$comment->subject ". ($comment->new ? theme_invoke("theme_mark") : "") ."</div></td><td align=\"right\" rowspan=\"2\" valign=\"top\">". $comment->moderation ."</td></tr>";
|
||||
$output .= " <tr><td><div style=\"font-size: 110%; font-weight: bold;\">$comment->subject ". ($comment->new ? theme("theme_mark") : "") ."</div></td><td align=\"right\" rowspan=\"2\" valign=\"top\">". $comment->moderation ."</td></tr>";
|
||||
$output .= " <tr><td><div style=\"margin-left: 10px; padding-bottom: 10px; font-size: 90%;\">". t("by %a on %b", array("%a" => format_name($comment), "%b" => format_date($comment->timestamp))) ."</div></td></tr>";
|
||||
$output .= " <tr><td colspan=\"2\">". check_output($comment->comment) ."</td></tr>";
|
||||
$output .= " <tr><td align=\"right\" colspan=\"2\">$link</td></tr>";
|
||||
|
@ -1310,7 +1310,7 @@ function comment_moderate() {
|
|||
}
|
||||
}
|
||||
|
||||
function comment_settings($mode, $order, $threshold, $comments_per_page) {
|
||||
function comment_save_settings($mode, $order, $threshold, $comments_per_page) {
|
||||
global $user;
|
||||
|
||||
if ($user->uid) {
|
||||
|
|
|
@ -20,7 +20,7 @@ function comment_system($field) {
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function comment_conf_options() {
|
||||
function comment_settings() {
|
||||
global $cmodes, $corder;
|
||||
|
||||
$output .= form_select(t("Default display mode"), "comment_default_mode", variable_get("comment_default_mode", 4), $cmodes, t("The default view for comments. Expanded views display the body of the comment. Threaded views keep replies together."));
|
||||
|
@ -340,7 +340,7 @@ function comment_links($comment, $return = 1) {
|
|||
$links[] = l(t("reply to this comment"), "comment/reply/$comment->nid/$comment->cid");
|
||||
}
|
||||
else {
|
||||
$links[] = theme_invoke("comment_post_forbidden");
|
||||
$links[] = theme("comment_post_forbidden");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -365,10 +365,10 @@ function comment_view($comment, $links = "", $visible = 1) {
|
|||
print "<a name=\"$comment->cid\"></a>\n";
|
||||
|
||||
if ($visible) {
|
||||
theme_invoke("comment", $comment, $links);
|
||||
theme("comment", $comment, $links);
|
||||
}
|
||||
else {
|
||||
theme_invoke("comment_folded", $comment);
|
||||
theme("comment_folded", $comment);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -458,7 +458,7 @@ function comment_render($node, $cid = 0) {
|
|||
|
||||
if ($comment_num && ((variable_get("comment_controls", 0) == 0) || (variable_get("comment_controls", 0) == 2))) {
|
||||
print "<form method=\"post\" action=\"". url("comment") ."\">\n";
|
||||
$theme->box(t("Control panel"), theme_invoke("comment_controls", $threshold, $mode, $order, $nid, $comment_page, $comment_num, $comments_per_page));
|
||||
$theme->box(t("Control panel"), theme("comment_controls", $threshold, $mode, $order, $nid, $comment_page, $comment_num, $comments_per_page));
|
||||
print form_hidden("nid", $nid);
|
||||
print "</form>";
|
||||
}
|
||||
|
@ -475,7 +475,7 @@ function comment_render($node, $cid = 0) {
|
|||
while ($comment = db_fetch_object($result)) {
|
||||
$comments[$comment->cid] = $comment;
|
||||
}
|
||||
theme_invoke("comment_flat_collapsed", $comments, $threshold_min);
|
||||
theme("comment_flat_collapsed", $comments, $threshold_min);
|
||||
}
|
||||
else if ($mode == 2) {
|
||||
/*
|
||||
|
@ -515,7 +515,7 @@ function comment_render($node, $cid = 0) {
|
|||
}
|
||||
}
|
||||
|
||||
theme_invoke("comment_flat_expanded", $comments, $threshold_min);
|
||||
theme("comment_flat_expanded", $comments, $threshold_min);
|
||||
|
||||
if (comment_user_can_moderate($node) && $show_moderate_button) {
|
||||
print "<div align=\"center\">". form_submit(t("Moderate comments")) ."</div><br />";
|
||||
|
@ -530,7 +530,7 @@ function comment_render($node, $cid = 0) {
|
|||
$comments[$comment->cid] = $comment;
|
||||
}
|
||||
if ($comments) {
|
||||
theme_invoke("comment_thread_min", $comments, $threshold_min);
|
||||
theme("comment_thread_min", $comments, $threshold_min);
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
@ -556,7 +556,7 @@ function comment_render($node, $cid = 0) {
|
|||
$page = 1;
|
||||
foreach ($structure as $cid => $depth) {
|
||||
if ($page == $comment_page) {
|
||||
theme_invoke("comment_thread_max", $comments[$cid], $threshold_min, $depth - 1);
|
||||
theme("comment_thread_max", $comments[$cid], $threshold_min, $depth - 1);
|
||||
}
|
||||
$comment_num++;
|
||||
if ($comment_num == $comments_per_page) {
|
||||
|
@ -580,7 +580,7 @@ function comment_render($node, $cid = 0) {
|
|||
|
||||
if ($comment_num && ((variable_get("comment_controls", 0) == 1) || (variable_get("comment_controls", 0) == 2))) {
|
||||
print "<form method=\"post\" action=\"". url("comment") ."\">\n";
|
||||
$theme->box(t("Control panel"), theme_invoke("comment_controls", $threshold, $mode, $order, $nid, $comment_page, $comment_num, $comments_per_page));
|
||||
$theme->box(t("Control panel"), theme("comment_controls", $threshold, $mode, $order, $nid, $comment_page, $comment_num, $comments_per_page));
|
||||
print form_hidden("nid", $nid);
|
||||
print "</form>";
|
||||
}
|
||||
|
@ -632,7 +632,7 @@ function comment_link($type, $node = 0, $main = 0) {
|
|||
$links[] = l(t("add new comment"), "comment/reply/$node->nid", array("title" => t("Add a new comment to this page.")));
|
||||
}
|
||||
else {
|
||||
$links[] = theme_invoke("comment_post_forbidden");
|
||||
$links[] = theme("comment_post_forbidden");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -648,7 +648,7 @@ function comment_link($type, $node = 0, $main = 0) {
|
|||
$links[] = l(t("add new comment"), "comment/reply/$node->nid", array("title" => t("Share your thoughts and opinions related to this posting.")));
|
||||
}
|
||||
else {
|
||||
$links[] = theme_invoke("comment_post_forbidden");
|
||||
$links[] = theme("comment_post_forbidden");
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
@ -717,9 +717,9 @@ function comment_page() {
|
|||
drupal_goto(url("node/view/". $edit["nid"]));
|
||||
}
|
||||
break;
|
||||
case t("Update settings"):
|
||||
case t("Save settings"):
|
||||
global $mode, $order, $threshold, $comments_per_page;
|
||||
comment_settings(check_query($mode), check_query($order), check_query($threshold), check_query($comments_per_page));
|
||||
comment_save_settings(check_query($mode), check_query($order), check_query($threshold), check_query($comments_per_page));
|
||||
drupal_goto(url("node/view/". $edit["nid"], "mode=$mode&order=$order&threshold=$threshold&comments_per_page=$comments_per_page"));
|
||||
break;
|
||||
}
|
||||
|
@ -1107,9 +1107,9 @@ function comment_controls($threshold = 1, $mode = 3, $order = 1, $nid, $page = 0
|
|||
$output .= comment_per_page_form($comments_per_page);
|
||||
$output .= comment_threshold($threshold);
|
||||
|
||||
$output .= " ". form_submit(t("Update settings"));
|
||||
$output .= " ". form_submit(t("Save settings"));
|
||||
|
||||
$output = form_item(t("Comment viewing options"), $output, t("Select your preferred way to display the comments and click 'Update settings' to submit your changes."));
|
||||
$output = form_item(t("Comment viewing options"), $output, t("Select your preferred way to display the comments and click 'Save settings' to submit your changes."));
|
||||
|
||||
if (($mode == 2 || $mode == 4) && $comment_num > $comments_per_page) {
|
||||
if ($page > 1) {
|
||||
|
@ -1165,7 +1165,7 @@ function comment_moderation_form($comment) {
|
|||
function comment($comment, $link = 0) {
|
||||
$output .= "<div style=\"border: 1px solid; padding: 10px;\">";
|
||||
$output .= "<table border=\"0\" cellpadding=\"0\" cellspacing=\"0\" width=\"100%\">";
|
||||
$output .= " <tr><td><div style=\"font-size: 110%; font-weight: bold;\">$comment->subject ". ($comment->new ? theme_invoke("theme_mark") : "") ."</div></td><td align=\"right\" rowspan=\"2\" valign=\"top\">". $comment->moderation ."</td></tr>";
|
||||
$output .= " <tr><td><div style=\"font-size: 110%; font-weight: bold;\">$comment->subject ". ($comment->new ? theme("theme_mark") : "") ."</div></td><td align=\"right\" rowspan=\"2\" valign=\"top\">". $comment->moderation ."</td></tr>";
|
||||
$output .= " <tr><td><div style=\"margin-left: 10px; padding-bottom: 10px; font-size: 90%;\">". t("by %a on %b", array("%a" => format_name($comment), "%b" => format_date($comment->timestamp))) ."</div></td></tr>";
|
||||
$output .= " <tr><td colspan=\"2\">". check_output($comment->comment) ."</td></tr>";
|
||||
$output .= " <tr><td align=\"right\" colspan=\"2\">$link</td></tr>";
|
||||
|
@ -1310,7 +1310,7 @@ function comment_moderate() {
|
|||
}
|
||||
}
|
||||
|
||||
function comment_settings($mode, $order, $threshold, $comments_per_page) {
|
||||
function comment_save_settings($mode, $order, $threshold, $comments_per_page) {
|
||||
global $user;
|
||||
|
||||
if ($user->uid) {
|
||||
|
|
|
@ -14,7 +14,7 @@ function development_system($field) {
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function development_conf_options() {
|
||||
function development_settings() {
|
||||
$output = form_select(t("Display query log"), "dev_query", variable_get("dev_query", 0), array(t("Disabled"), t("Enabled")), t("Display a log of the database queries needed to generate the current page, and the execution time for each."));
|
||||
return $output;
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@ function drupal_system($field) {
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function drupal_conf_options() {
|
||||
function drupal_settings() {
|
||||
$output .= form_textfield("Drupal XML-RPC server", "drupal_server", variable_get("drupal_server", "http://www.drupal.org/xmlrpc.php"), 55, 128, "The URL of your root Drupal XML-RPC server.");
|
||||
$output .= form_select("Drupal directory", "drupal_directory", variable_get("drupal_directory", 0), array("Disabled", "Enabled"), "If enabled, your Drupal site will make itself know to the Drupal directory at the specified Drupal XML-RPC server. For this to work properly, you have to set your site's name, e-mail address, slogan and mission statement. When the \"Drupal XML-RPC server\" field is set to \"http://www.drupal.org/xmlrpc.php\", your website will get listed on <a href=\"http://www.drupal.org/\">http://www.drupal.org/</a>. Requires crontab.");
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ function drupal_system($field) {
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function drupal_conf_options() {
|
||||
function drupal_settings() {
|
||||
$output .= form_textfield("Drupal XML-RPC server", "drupal_server", variable_get("drupal_server", "http://www.drupal.org/xmlrpc.php"), 55, 128, "The URL of your root Drupal XML-RPC server.");
|
||||
$output .= form_select("Drupal directory", "drupal_directory", variable_get("drupal_directory", 0), array("Disabled", "Enabled"), "If enabled, your Drupal site will make itself know to the Drupal directory at the specified Drupal XML-RPC server. For this to work properly, you have to set your site's name, e-mail address, slogan and mission statement. When the \"Drupal XML-RPC server\" field is set to \"http://www.drupal.org/xmlrpc.php\", your website will get listed on <a href=\"http://www.drupal.org/\">http://www.drupal.org/</a>. Requires crontab.");
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@ function forum_perm() {
|
|||
return array("create forum topics");
|
||||
}
|
||||
|
||||
function forum_conf_options() {
|
||||
function forum_settings() {
|
||||
|
||||
if (module_exist("taxonomy")) {
|
||||
$vocs[0] = "<". t("none") .">";
|
||||
|
@ -490,7 +490,7 @@ function forum_page() {
|
|||
$topics = forum_get_topics($tid, $sortby, $forum_per_page);
|
||||
}
|
||||
|
||||
theme_invoke("forum_render", $forums, $topics, $parents, $tid, $sortby, $forum_per_page, $offset);
|
||||
theme("forum_render", $forums, $topics, $parents, $tid, $sortby, $forum_per_page, $offset);
|
||||
}
|
||||
else {
|
||||
$theme->header();
|
||||
|
@ -513,15 +513,15 @@ function forum_render($forums, $topics, $parents, $tid, $sortby, $forum_per_page
|
|||
// forum list, topics list, topic browser and "add new topic" link
|
||||
global $theme;
|
||||
|
||||
$output .= theme_invoke("forum_forum_list", $forums, $parents, $tid);
|
||||
$output .= theme("forum_forum_list", $forums, $parents, $tid);
|
||||
if ($tid && !in_array($tid, variable_get("forum_containers", array()))) {
|
||||
$output .= theme_invoke("forum_topic_list", $tid, $topics, $sortby, $forum_per_page, $offset);
|
||||
$output .= theme("forum_topic_list", $tid, $topics, $sortby, $forum_per_page, $offset);
|
||||
}
|
||||
|
||||
$theme->header();
|
||||
$theme->box(t("Discussion forum"), $output);
|
||||
if ($tid && !in_array($tid, variable_get("forum_containers", array()))) {
|
||||
$theme->box(t("Control panel"), theme_invoke("forum_topic_browser", $sortby, $forum_per_page, $offset));
|
||||
$theme->box(t("Control panel"), theme("forum_topic_browser", $sortby, $forum_per_page, $offset));
|
||||
}
|
||||
$theme->footer();
|
||||
}
|
||||
|
|
|
@ -26,7 +26,7 @@ function forum_perm() {
|
|||
return array("create forum topics");
|
||||
}
|
||||
|
||||
function forum_conf_options() {
|
||||
function forum_settings() {
|
||||
|
||||
if (module_exist("taxonomy")) {
|
||||
$vocs[0] = "<". t("none") .">";
|
||||
|
@ -490,7 +490,7 @@ function forum_page() {
|
|||
$topics = forum_get_topics($tid, $sortby, $forum_per_page);
|
||||
}
|
||||
|
||||
theme_invoke("forum_render", $forums, $topics, $parents, $tid, $sortby, $forum_per_page, $offset);
|
||||
theme("forum_render", $forums, $topics, $parents, $tid, $sortby, $forum_per_page, $offset);
|
||||
}
|
||||
else {
|
||||
$theme->header();
|
||||
|
@ -513,15 +513,15 @@ function forum_render($forums, $topics, $parents, $tid, $sortby, $forum_per_page
|
|||
// forum list, topics list, topic browser and "add new topic" link
|
||||
global $theme;
|
||||
|
||||
$output .= theme_invoke("forum_forum_list", $forums, $parents, $tid);
|
||||
$output .= theme("forum_forum_list", $forums, $parents, $tid);
|
||||
if ($tid && !in_array($tid, variable_get("forum_containers", array()))) {
|
||||
$output .= theme_invoke("forum_topic_list", $tid, $topics, $sortby, $forum_per_page, $offset);
|
||||
$output .= theme("forum_topic_list", $tid, $topics, $sortby, $forum_per_page, $offset);
|
||||
}
|
||||
|
||||
$theme->header();
|
||||
$theme->box(t("Discussion forum"), $output);
|
||||
if ($tid && !in_array($tid, variable_get("forum_containers", array()))) {
|
||||
$theme->box(t("Control panel"), theme_invoke("forum_topic_browser", $sortby, $forum_per_page, $offset));
|
||||
$theme->box(t("Control panel"), theme("forum_topic_browser", $sortby, $forum_per_page, $offset));
|
||||
}
|
||||
$theme->footer();
|
||||
}
|
||||
|
|
|
@ -16,7 +16,7 @@ function import_system($field){
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function import_conf_options() {
|
||||
function import_settings() {
|
||||
$number = array(5 => 5, 10 => 10, 15 => 15, 20 => 20, 25 => 25, 30 => 30, 35 => 35, 40 => 40, 45 => 45, 50 => 50, 55 => 55, 60 => 60, 65 => 65, 70 => 70, 75 => 75, 80 => 80, 85 => 85, 90 => 90, 95 => 95, 100 => 100);
|
||||
$output .= form_select("Items per block", "import_block_limit", variable_get("import_block_limit", 15), $number, "The maximum number of news items displayed in one block.");
|
||||
$output .= form_select("Items per page", "import_page_limit", variable_get("import_page_limit", 75), $number, "The maximum number of news items displayed on one page.");
|
||||
|
|
|
@ -34,7 +34,7 @@ function node_title_list($result, $title = NULL) {
|
|||
$items[] = l($node->title, "node/view/$node->nid", array("title" => t("Comments: %number", array("%number" => $number))));
|
||||
}
|
||||
|
||||
return theme_invoke("theme_item_list", $items, $title);
|
||||
return theme("theme_item_list", $items, $title);
|
||||
}
|
||||
|
||||
function node_teaser($body) {
|
||||
|
@ -385,7 +385,7 @@ function node_search($keys) {
|
|||
return $find;
|
||||
}
|
||||
|
||||
function node_conf_options() {
|
||||
function node_settings() {
|
||||
$output .= form_select(t("Number of posts on main page"), "default_nodes_main", variable_get("default_nodes_main", 10), array(1 => 1, 2 => 2, 3 => 3, 4 => 4, 5 => 5, 6 => 6, 7 => 7, 8 => 8, 9 => 9, 10 => 10, 15 => 15, 20 => 20, 25 => 25, 30 => 30), t("The default maximum number of posts to display on overview pages such as the main page."));
|
||||
$output .= form_select(t("Length of trimmed posts"), "teaser_length", variable_get("teaser_length", 600), array(0 => t("Unlimited"), 200 => t("200 characters"), 400 => t("400 characters"), 600 => t("600 characters"), 800 => t("800 characters"), 1000 => t("1000 characters"), 1200 => t("1200 characters"), 1400 => t("1400 characters"), 1600 => t("1600 characters"), 1800 => t("1800 characters"), 2000 => t("2000 characters")), t("The maximum number of characters used in the trimmed version of a post. Drupal will use this setting to determine at which offset long posts should be trimmed. The trimmed version of a post is typically used as a teaser when displaying the post on the main page, in XML feeds, etc. To disable teasers, set to 'Unlimited'."));
|
||||
return $output;
|
||||
|
@ -742,7 +742,7 @@ function node_validate($node, &$error) {
|
|||
*/
|
||||
|
||||
if (isset($node->title) && !$node->title) {
|
||||
$error["title"] = theme_invoke("theme_error", t("You have to specify a valid title."));
|
||||
$error["title"] = theme("theme_error", t("You have to specify a valid title."));
|
||||
}
|
||||
|
||||
if (user_access("administer nodes")) {
|
||||
|
@ -775,7 +775,7 @@ function node_validate($node, &$error) {
|
|||
$node->uid = $account->uid;
|
||||
}
|
||||
else {
|
||||
$error["name"] = theme_invoke("theme_error", t("The name '%u' does not exist.", array ("%u" => $node->name)));
|
||||
$error["name"] = theme("theme_error", t("The name '%u' does not exist.", array ("%u" => $node->name)));
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -786,7 +786,7 @@ function node_validate($node, &$error) {
|
|||
$node->created = strtotime($node->date);
|
||||
}
|
||||
else {
|
||||
$error["date"] = theme_invoke("theme_error", t("You have to specifiy a valid date."));
|
||||
$error["date"] = theme("theme_error", t("You have to specifiy a valid date."));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -34,7 +34,7 @@ function node_title_list($result, $title = NULL) {
|
|||
$items[] = l($node->title, "node/view/$node->nid", array("title" => t("Comments: %number", array("%number" => $number))));
|
||||
}
|
||||
|
||||
return theme_invoke("theme_item_list", $items, $title);
|
||||
return theme("theme_item_list", $items, $title);
|
||||
}
|
||||
|
||||
function node_teaser($body) {
|
||||
|
@ -385,7 +385,7 @@ function node_search($keys) {
|
|||
return $find;
|
||||
}
|
||||
|
||||
function node_conf_options() {
|
||||
function node_settings() {
|
||||
$output .= form_select(t("Number of posts on main page"), "default_nodes_main", variable_get("default_nodes_main", 10), array(1 => 1, 2 => 2, 3 => 3, 4 => 4, 5 => 5, 6 => 6, 7 => 7, 8 => 8, 9 => 9, 10 => 10, 15 => 15, 20 => 20, 25 => 25, 30 => 30), t("The default maximum number of posts to display on overview pages such as the main page."));
|
||||
$output .= form_select(t("Length of trimmed posts"), "teaser_length", variable_get("teaser_length", 600), array(0 => t("Unlimited"), 200 => t("200 characters"), 400 => t("400 characters"), 600 => t("600 characters"), 800 => t("800 characters"), 1000 => t("1000 characters"), 1200 => t("1200 characters"), 1400 => t("1400 characters"), 1600 => t("1600 characters"), 1800 => t("1800 characters"), 2000 => t("2000 characters")), t("The maximum number of characters used in the trimmed version of a post. Drupal will use this setting to determine at which offset long posts should be trimmed. The trimmed version of a post is typically used as a teaser when displaying the post on the main page, in XML feeds, etc. To disable teasers, set to 'Unlimited'."));
|
||||
return $output;
|
||||
|
@ -742,7 +742,7 @@ function node_validate($node, &$error) {
|
|||
*/
|
||||
|
||||
if (isset($node->title) && !$node->title) {
|
||||
$error["title"] = theme_invoke("theme_error", t("You have to specify a valid title."));
|
||||
$error["title"] = theme("theme_error", t("You have to specify a valid title."));
|
||||
}
|
||||
|
||||
if (user_access("administer nodes")) {
|
||||
|
@ -775,7 +775,7 @@ function node_validate($node, &$error) {
|
|||
$node->uid = $account->uid;
|
||||
}
|
||||
else {
|
||||
$error["name"] = theme_invoke("theme_error", t("The name '%u' does not exist.", array ("%u" => $node->name)));
|
||||
$error["name"] = theme("theme_error", t("The name '%u' does not exist.", array ("%u" => $node->name)));
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -786,7 +786,7 @@ function node_validate($node, &$error) {
|
|||
$node->created = strtotime($node->date);
|
||||
}
|
||||
else {
|
||||
$error["date"] = theme_invoke("theme_error", t("You have to specifiy a valid date."));
|
||||
$error["date"] = theme("theme_error", t("You have to specifiy a valid date."));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -91,12 +91,12 @@ function poll_form(&$node, &$help, &$error) {
|
|||
}
|
||||
|
||||
if ($node->chvotes[$i] < 0) {
|
||||
$error["chvotes][$i"] = theme_invoke("theme_error", t("Negative values are not allowed."));
|
||||
$error["chvotes][$i"] = theme("theme_error", t("Negative values are not allowed."));
|
||||
}
|
||||
}
|
||||
|
||||
if ($actualchoices < 2) {
|
||||
$error["choice][0"] = theme_invoke("theme_error", t("You must fill in at least two choices."));
|
||||
$error["choice][0"] = theme("theme_error", t("You must fill in at least two choices."));
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -91,12 +91,12 @@ function poll_form(&$node, &$help, &$error) {
|
|||
}
|
||||
|
||||
if ($node->chvotes[$i] < 0) {
|
||||
$error["chvotes][$i"] = theme_invoke("theme_error", t("Negative values are not allowed."));
|
||||
$error["chvotes][$i"] = theme("theme_error", t("Negative values are not allowed."));
|
||||
}
|
||||
}
|
||||
|
||||
if ($actualchoices < 2) {
|
||||
$error["choice][0"] = theme_invoke("theme_error", t("You must fill in at least two choices."));
|
||||
$error["choice][0"] = theme("theme_error", t("You must fill in at least two choices."));
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -40,7 +40,7 @@ function profile_system($field){
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function profile_conf_options() {
|
||||
function profile_settings() {
|
||||
global $profile_fields;
|
||||
if (!$profile_fields) {
|
||||
_profile_init();
|
||||
|
@ -99,8 +99,8 @@ function profile_user($type, $edit, &$user) {
|
|||
}
|
||||
|
||||
function profile_required($title) {
|
||||
// this pleads "theme_invoke, theme_invoke" ;)
|
||||
return $title ." ". theme_invoke("theme_mark");
|
||||
// this pleads "theme, theme" ;)
|
||||
return $title ." ". theme("theme_mark");
|
||||
}
|
||||
|
||||
function _profile_form($edit, $mode) {
|
||||
|
|
|
@ -40,7 +40,7 @@ function profile_system($field){
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function profile_conf_options() {
|
||||
function profile_settings() {
|
||||
global $profile_fields;
|
||||
if (!$profile_fields) {
|
||||
_profile_init();
|
||||
|
@ -99,8 +99,8 @@ function profile_user($type, $edit, &$user) {
|
|||
}
|
||||
|
||||
function profile_required($title) {
|
||||
// this pleads "theme_invoke, theme_invoke" ;)
|
||||
return $title ." ". theme_invoke("theme_mark");
|
||||
// this pleads "theme, theme" ;)
|
||||
return $title ." ". theme("theme_mark");
|
||||
}
|
||||
|
||||
function _profile_form($edit, $mode) {
|
||||
|
|
|
@ -6,7 +6,7 @@ function queue_system($field){
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function queue_conf_options() {
|
||||
function queue_settings() {
|
||||
$threshold_post = array(1 => 1, 2 => 2, 3 => 3, 4 => 4, 5 => 5, 6 => 6, 7 => 7, 8 => 8, 9 => 9, 10 => 10, 11 => 11, 12 => 12, 13 => 13, 14 => 14, 15 => 15, 20 => 20, 25 => 25, 30 => 30, 35 => 35, 40 => 40, 45 => 45, 50 => 50, 60 => 60, 70 => 70, 80 => 80, 90 => 90, 100 => 100);
|
||||
$threshold_dump = array(-1 => -1, -2 => -2, -3 => -3, -4 => -4, -5 => -5, -6 => -6, -7 => -7, -8 => -8, -9 => -9, -10 => -10, -11 => -11, -12 => -12, -13 => -13, -14 => -14, -15 => -15, -20 => -20, -25 => -25, -30 => -30);
|
||||
$threshold_expire = array(1 => 1, 2 => 2, 3 => 3, 4 => 4, 5 => 5, 6 => 6, 7 => 7, 8 => 8, 9 => 9, 10 => 10, 11 => 11, 12 => 12, 13 => 13, 14 => 14, 15 => 15, 20 => 20, 25 => 25, 30 => 30, 35 => 35, 40 => 40, 45 => 45, 50 => 50, 60 => 60, 70 => 70, 80 => 80, 90 => 90, 100 => 100);
|
||||
|
|
|
@ -35,7 +35,7 @@ function search_link($type) {
|
|||
return $links ? $links : array();
|
||||
}
|
||||
|
||||
function search_conf_options() {
|
||||
function search_settings() {
|
||||
$output = form_textfield(t("Minimum word length to index"), "minimum_word_size", variable_get("minimum_word_size", 2), 10, 10, t("The number of characters a word has to be to be indexed. Words shorter than this will not be searchable."));
|
||||
$output .= form_textfield(t("Minimum word length to search for"), "remove_short", variable_get("remove_short", 0), 10, 10, t("The number of characters a word has to be to be searched for."));
|
||||
$output .= form_textarea(t("Noise words"), "noisewords", variable_get("noisewords", ""), 70, 10, t("These words will not be indexed, enter comma separated list, linebreaks and whitespace do not matter. Example: and, or, not, a, to, I, it, ..."));
|
||||
|
|
|
@ -35,7 +35,7 @@ function search_link($type) {
|
|||
return $links ? $links : array();
|
||||
}
|
||||
|
||||
function search_conf_options() {
|
||||
function search_settings() {
|
||||
$output = form_textfield(t("Minimum word length to index"), "minimum_word_size", variable_get("minimum_word_size", 2), 10, 10, t("The number of characters a word has to be to be indexed. Words shorter than this will not be searchable."));
|
||||
$output .= form_textfield(t("Minimum word length to search for"), "remove_short", variable_get("remove_short", 0), 10, 10, t("The number of characters a word has to be to be searched for."));
|
||||
$output .= form_textarea(t("Noise words"), "noisewords", variable_get("noisewords", ""), 70, 10, t("These words will not be indexed, enter comma separated list, linebreaks and whitespace do not matter. Example: and, or, not, a, to, I, it, ..."));
|
||||
|
|
|
@ -628,7 +628,7 @@ function statistics_admin_userpage_config($edit) {
|
|||
|
||||
|
||||
/* Adds configure option to the main configure site admin page */
|
||||
function statistics_conf_options() {
|
||||
function statistics_settings() {
|
||||
/* access log options */
|
||||
$output = form_select(t("Enable access log"), "statistics_enable_access_log", variable_get("statistics_enable_access_log", 0), array("1" => t("Enabled"), "0" => t("Disabled")), t("Log each page access. Required for referrer statistics."));
|
||||
$period = array(3600 => format_interval(3600), 10800 => format_interval(10800), 21600 => format_interval(21600), 32400 => format_interval(32400), 43200 => format_interval(43200), 86400 => format_interval(86400), 172800 => format_interval(172800), 259200 => format_interval(259200), 604800 => format_interval(604800), 1209600 => format_interval(1209600), 2419200 => format_interval(2419200), 4838400 => format_interval(4838400), 9676800 => format_interval(9676800));
|
||||
|
@ -788,7 +788,7 @@ function statistics_display_online_block() {
|
|||
}
|
||||
|
||||
$output .= "<br /><br />";
|
||||
$output .= theme_invoke("theme_item_list", $items, variable_get("statistics_block_online_subtitle", "Online users:"));
|
||||
$output .= theme("theme_item_list", $items, variable_get("statistics_block_online_subtitle", "Online users:"));
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -628,7 +628,7 @@ function statistics_admin_userpage_config($edit) {
|
|||
|
||||
|
||||
/* Adds configure option to the main configure site admin page */
|
||||
function statistics_conf_options() {
|
||||
function statistics_settings() {
|
||||
/* access log options */
|
||||
$output = form_select(t("Enable access log"), "statistics_enable_access_log", variable_get("statistics_enable_access_log", 0), array("1" => t("Enabled"), "0" => t("Disabled")), t("Log each page access. Required for referrer statistics."));
|
||||
$period = array(3600 => format_interval(3600), 10800 => format_interval(10800), 21600 => format_interval(21600), 32400 => format_interval(32400), 43200 => format_interval(43200), 86400 => format_interval(86400), 172800 => format_interval(172800), 259200 => format_interval(259200), 604800 => format_interval(604800), 1209600 => format_interval(1209600), 2419200 => format_interval(2419200), 4838400 => format_interval(4838400), 9676800 => format_interval(9676800));
|
||||
|
@ -788,7 +788,7 @@ function statistics_display_online_block() {
|
|||
}
|
||||
|
||||
$output .= "<br /><br />";
|
||||
$output .= theme_invoke("theme_item_list", $items, variable_get("statistics_block_online_subtitle", "Online users:"));
|
||||
$output .= theme("theme_item_list", $items, variable_get("statistics_block_online_subtitle", "Online users:"));
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
|
|
@ -12,7 +12,7 @@ function story_system($field){
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function story_conf_options() {
|
||||
function story_settings() {
|
||||
$output .= form_textarea("Explanation or submission guidelines", "story_help", variable_get("story_help", ""), 55, 4, "This text will be displayed at the top of the story submission form. Useful for helping or instructing your users.");
|
||||
$output .= form_select(t("Minimum number of words"), "minimum_story_size", variable_get("minimum_story_size", 0), array(0 => "0 words", 10 => "10 words", 25 => "25 words", 50 => "50 words", 75 => "75 words", 100 => "100 words", 125 => "125 words", 150 => "150 words", 175 => "175 words", 200 => "200 words"), t("The minimum number of words a personal story entry should consist of. This can be useful to rule out submissions that do not meet the site's standards, such as short test posts."));
|
||||
|
||||
|
|
|
@ -12,7 +12,7 @@ function story_system($field){
|
|||
return $system[$field];
|
||||
}
|
||||
|
||||
function story_conf_options() {
|
||||
function story_settings() {
|
||||
$output .= form_textarea("Explanation or submission guidelines", "story_help", variable_get("story_help", ""), 55, 4, "This text will be displayed at the top of the story submission form. Useful for helping or instructing your users.");
|
||||
$output .= form_select(t("Minimum number of words"), "minimum_story_size", variable_get("minimum_story_size", 0), array(0 => "0 words", 10 => "10 words", 25 => "25 words", 50 => "50 words", 75 => "75 words", 100 => "100 words", 125 => "125 words", 150 => "150 words", 175 => "175 words", 200 => "200 words"), t("The minimum number of words a personal story entry should consist of. This can be useful to rule out submissions that do not meet the site's standards, such as short test posts."));
|
||||
|
||||
|
|
|
@ -111,8 +111,8 @@ function system_view_modules() {
|
|||
$output .= "<hr />\n";
|
||||
|
||||
foreach (module_list() as $name) {
|
||||
if (module_hook($name, "conf_options")) {
|
||||
$output .= "<h3><a name=\"$name\">". ucfirst(t("$name")) ." " . t("settings") . "</a></h3>". module_invoke($name, "conf_options") ."<hr />\n";
|
||||
if (module_hook($name, "settings")) {
|
||||
$output .= "<h3><a name=\"$name\">". ucfirst(t("$name")) ." " . t("settings") . "</a></h3>". module_invoke($name, "settings") ."<hr />\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -120,9 +120,11 @@ function system_view_modules() {
|
|||
}
|
||||
|
||||
function system_view_themes() {
|
||||
foreach (theme_list() as $name) {
|
||||
if (module_hook($name, "conf_options")) {
|
||||
$output .= "<h3><a name=\"$name\">". ucfirst(t("$name")) ." " . t("settings") . "</a></h3>". module_invoke($name, "conf_options") ."<hr />\n";
|
||||
foreach (theme_list() as $theme) {
|
||||
include_once "$theme->filename";
|
||||
$function = $theme->name ."_options";
|
||||
if (function_exists($function)) {
|
||||
$output .= "<h3><a name=\"$theme->name\">". ucfirst(t("$theme->name")) ." " . t("settings") . "</a></h3>". $function() ."<hr />\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -182,7 +184,7 @@ function system_view($type) {
|
|||
break;
|
||||
default:
|
||||
foreach (module_list() as $name) {
|
||||
if (module_hook($name, "conf_options")) {
|
||||
if (module_hook($name, "settings")) {
|
||||
$links[] = "<a href=\"#$name\">". t("$name") ."</a>";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -111,8 +111,8 @@ function system_view_modules() {
|
|||
$output .= "<hr />\n";
|
||||
|
||||
foreach (module_list() as $name) {
|
||||
if (module_hook($name, "conf_options")) {
|
||||
$output .= "<h3><a name=\"$name\">". ucfirst(t("$name")) ." " . t("settings") . "</a></h3>". module_invoke($name, "conf_options") ."<hr />\n";
|
||||
if (module_hook($name, "settings")) {
|
||||
$output .= "<h3><a name=\"$name\">". ucfirst(t("$name")) ." " . t("settings") . "</a></h3>". module_invoke($name, "settings") ."<hr />\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -120,9 +120,11 @@ function system_view_modules() {
|
|||
}
|
||||
|
||||
function system_view_themes() {
|
||||
foreach (theme_list() as $name) {
|
||||
if (module_hook($name, "conf_options")) {
|
||||
$output .= "<h3><a name=\"$name\">". ucfirst(t("$name")) ." " . t("settings") . "</a></h3>". module_invoke($name, "conf_options") ."<hr />\n";
|
||||
foreach (theme_list() as $theme) {
|
||||
include_once "$theme->filename";
|
||||
$function = $theme->name ."_options";
|
||||
if (function_exists($function)) {
|
||||
$output .= "<h3><a name=\"$theme->name\">". ucfirst(t("$theme->name")) ." " . t("settings") . "</a></h3>". $function() ."<hr />\n";
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -182,7 +184,7 @@ function system_view($type) {
|
|||
break;
|
||||
default:
|
||||
foreach (module_list() as $name) {
|
||||
if (module_hook($name, "conf_options")) {
|
||||
if (module_hook($name, "settings")) {
|
||||
$links[] = "<a href=\"#$name\">". t("$name") ."</a>";
|
||||
}
|
||||
}
|
||||
|
|
|
@ -87,7 +87,7 @@ function throttle_help() {
|
|||
|
||||
|
||||
/* Adds configure option to the main configure site admin page */
|
||||
function throttle_conf_options() {
|
||||
function throttle_settings() {
|
||||
/* access log options */
|
||||
$output .= form_select(t("Enable auto-throttle"), "statistics_enable_auto_throttle", variable_get("statistics_enable_auto_throttle", 0), array("1" => t("enabled"), "0" => t("disabled")), "Enable auto-throttling congestion control mechanism. Allows your site to adapt under extreme user loads. Requires that 'access log' be enabled.");
|
||||
$throttles = array(1 => "1 (0,1,2,3,4,5)", 5 => "5 (0,5,10,15,20,25)", 10 => "10 (0,10,20,30,40,50)", 12 => "12 (0,12,24,36,48,60)", 15 => "15 (0,15,30,45,60,75)", 20 => "20 (0,20,40,60,80,100)", 30 => "30 (0,30,60,90,120,150)", 50 => "50 (0,50,100,150,200,250)", 60 => "60 (0,60,120,180,240,300)", 100 => "100 (0,100,200,300,400,500", 500 => "500 (0,500,1000,1500,2000,2500", 1000 => "1000 (0,1000,2000,3000,4000,5000)");
|
||||
|
|
|
@ -87,7 +87,7 @@ function throttle_help() {
|
|||
|
||||
|
||||
/* Adds configure option to the main configure site admin page */
|
||||
function throttle_conf_options() {
|
||||
function throttle_settings() {
|
||||
/* access log options */
|
||||
$output .= form_select(t("Enable auto-throttle"), "statistics_enable_auto_throttle", variable_get("statistics_enable_auto_throttle", 0), array("1" => t("enabled"), "0" => t("disabled")), "Enable auto-throttling congestion control mechanism. Allows your site to adapt under extreme user loads. Requires that 'access log' be enabled.");
|
||||
$throttles = array(1 => "1 (0,1,2,3,4,5)", 5 => "5 (0,5,10,15,20,25)", 10 => "10 (0,10,20,30,40,50)", 12 => "12 (0,12,24,36,48,60)", 15 => "15 (0,15,30,45,60,75)", 20 => "20 (0,20,40,60,80,100)", 30 => "30 (0,30,60,90,120,150)", 50 => "50 (0,50,100,150,200,250)", 60 => "60 (0,60,120,180,240,300)", 100 => "100 (0,100,200,300,400,500", 500 => "500 (0,500,1000,1500,2000,2500", 1000 => "1000 (0,1000,2000,3000,4000,5000)");
|
||||
|
|
|
@ -20,7 +20,7 @@ function tracker_link($type) {
|
|||
return $links ? $links : array();
|
||||
}
|
||||
|
||||
function tracker_conf_options() {
|
||||
function tracker_settings() {
|
||||
$period = array(3600 => format_interval(3600), 10800 => format_interval(10800), 21600 => format_interval(21600), 32400 => format_interval(32400), 43200 => format_interval(43200), 86400 => format_interval(86400), 172800 => format_interval(172800), 259200 => format_interval(259200), 604800 => format_interval(604800), 1209600 => format_interval(1209600), 2419200 => format_interval(2419200), 1000000000 => "All");
|
||||
$output .= form_select("Show comments more recent than", "tracker_period", variable_get("tracker_period", 259200), $period, "Comments younger than this get displayed.");
|
||||
return $output;
|
||||
|
@ -48,7 +48,7 @@ function tracker_comments($id = 0) {
|
|||
|
||||
$output .= "<ul>";
|
||||
while ($comment = db_fetch_object($cresult)) {
|
||||
$output .= " <li>". l($comment->subject, "node/view/$node->nid#$comment->cid") ." ". t("by") ." ". format_name($comment) ." (". t("replies") .": ". comment_num_replies($comment->cid) .") ". (comment_is_new($comment) ? theme_invoke("theme_mark") : "") ."</li>\n";
|
||||
$output .= " <li>". l($comment->subject, "node/view/$node->nid#$comment->cid") ." ". t("by") ." ". format_name($comment) ." (". t("replies") .": ". comment_num_replies($comment->cid) .") ". (comment_is_new($comment) ? theme("theme_mark") : "") ."</li>\n";
|
||||
}
|
||||
$output .= " </ul>\n";
|
||||
}
|
||||
|
|
|
@ -20,7 +20,7 @@ function tracker_link($type) {
|
|||
return $links ? $links : array();
|
||||
}
|
||||
|
||||
function tracker_conf_options() {
|
||||
function tracker_settings() {
|
||||
$period = array(3600 => format_interval(3600), 10800 => format_interval(10800), 21600 => format_interval(21600), 32400 => format_interval(32400), 43200 => format_interval(43200), 86400 => format_interval(86400), 172800 => format_interval(172800), 259200 => format_interval(259200), 604800 => format_interval(604800), 1209600 => format_interval(1209600), 2419200 => format_interval(2419200), 1000000000 => "All");
|
||||
$output .= form_select("Show comments more recent than", "tracker_period", variable_get("tracker_period", 259200), $period, "Comments younger than this get displayed.");
|
||||
return $output;
|
||||
|
@ -48,7 +48,7 @@ function tracker_comments($id = 0) {
|
|||
|
||||
$output .= "<ul>";
|
||||
while ($comment = db_fetch_object($cresult)) {
|
||||
$output .= " <li>". l($comment->subject, "node/view/$node->nid#$comment->cid") ." ". t("by") ." ". format_name($comment) ." (". t("replies") .": ". comment_num_replies($comment->cid) .") ". (comment_is_new($comment) ? theme_invoke("theme_mark") : "") ."</li>\n";
|
||||
$output .= " <li>". l($comment->subject, "node/view/$node->nid#$comment->cid") ." ". t("by") ." ". format_name($comment) ." (". t("replies") .": ". comment_num_replies($comment->cid) .") ". (comment_is_new($comment) ? theme("theme_mark") : "") ."</li>\n";
|
||||
}
|
||||
$output .= " </ul>\n";
|
||||
}
|
||||
|
|
|
@ -347,7 +347,7 @@ function user_block($op = "list", $delta = 0) {
|
|||
}
|
||||
$items[] = l(t("Request new password"), "user/password", array("title" => t("Request new password via e-mail.")));
|
||||
|
||||
$output .= theme_invoke("theme_item_list", $items);
|
||||
$output .= theme("theme_item_list", $items);
|
||||
|
||||
$block["subject"] = t("Log in");
|
||||
$block["content"] = "<div style=\"{ white-space: nowrap; }\">$output</div>";
|
||||
|
@ -356,10 +356,10 @@ function user_block($op = "list", $delta = 0) {
|
|||
break;
|
||||
case 1:
|
||||
if ($user->uid) {
|
||||
$content[] = theme_invoke("theme_item_list", module_invoke_all("link", "menu.create"));
|
||||
$content[] = theme_invoke("theme_item_list", module_invoke_all("link", "menu.view"));
|
||||
$content[] = theme_invoke("theme_item_list", module_invoke_all("link", "menu.settings"));
|
||||
$content[] = theme_invoke("theme_item_list", module_invoke_all("link", "menu.misc"));
|
||||
$content[] = theme("theme_item_list", module_invoke_all("link", "menu.create"));
|
||||
$content[] = theme("theme_item_list", module_invoke_all("link", "menu.view"));
|
||||
$content[] = theme("theme_item_list", module_invoke_all("link", "menu.settings"));
|
||||
$content[] = theme("theme_item_list", module_invoke_all("link", "menu.misc"));
|
||||
|
||||
$output = implode($content, "<br />");
|
||||
|
||||
|
@ -375,7 +375,7 @@ function user_block($op = "list", $delta = 0) {
|
|||
$items[] = l((strlen($account->name) > 15 ? substr($account->name, 0, 15) . '...' : $account->name), "user/view/$account->uid");
|
||||
}
|
||||
|
||||
$output = theme_invoke("theme_item_list", $items);
|
||||
$output = theme("theme_item_list", $items);
|
||||
|
||||
$block["subject"] = t("Who's new");
|
||||
$block["content"] = $output;
|
||||
|
@ -611,7 +611,7 @@ function user_login($edit = array(), $msg = "") {
|
|||
*/
|
||||
|
||||
if ($error) {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -714,7 +714,7 @@ function user_pass($edit = array()) {
|
|||
|
||||
// Display error message if necessary.
|
||||
if ($error) {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -836,7 +836,7 @@ function user_register($edit = array()) {
|
|||
}
|
||||
else {
|
||||
if ($error) {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -953,7 +953,7 @@ function user_edit($edit = array()) {
|
|||
}
|
||||
|
||||
if ($error) {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
|
||||
if (!$edit) {
|
||||
|
@ -1114,7 +1114,7 @@ function user_page() {
|
|||
|
||||
/*** Administrative features ***********************************************/
|
||||
|
||||
function user_conf_options() {
|
||||
function user_settings() {
|
||||
$output .= form_select(t("Public registrations"), "user_register", variable_get("user_register", 1), array(t("Only site administrators can create new user accounts."), t("Visitors can create accounts and no administrator approval is required."), t("Visitors can create accounts but administrator approval is required.")));
|
||||
$output .= form_textfield(t("Password words"), "user_password", variable_get("user_password", "foo,bar,guy,neo,tux,moo,sun,asm,dot,god,axe,geek,nerd,fish,hack,star,mice,warp,moon,hero,cola,girl,fish,java,perl,boss,dark,sith,jedi,drop,mojo"), 55, 256, t("A comma separated list of short words that can be concatenated to generate human-readable passwords."));
|
||||
$output .= form_select(t("Remember authenticated users"), "user_remember", variable_get("user_remember", 0), array(t("Let the user decide whether he should be logged out when leaving the site."), t("Authenticated users are not logged out upon leaving the site."), t("Authenticated users are logged out upon leaving the site.")));
|
||||
|
@ -1156,7 +1156,7 @@ function user_admin_create($edit = array()) {
|
|||
else {
|
||||
|
||||
if ($error) {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
|
||||
$output .= form_textfield(t("Username"), "name", $edit["name"], 30, 55, t("Provide the username of the new account."));
|
||||
|
@ -1420,7 +1420,7 @@ function user_admin_edit($edit = array()) {
|
|||
$output .= status(t("your user information changes have been saved."));
|
||||
}
|
||||
else {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
}
|
||||
else if ($op == t("Delete account")) {
|
||||
|
|
|
@ -347,7 +347,7 @@ function user_block($op = "list", $delta = 0) {
|
|||
}
|
||||
$items[] = l(t("Request new password"), "user/password", array("title" => t("Request new password via e-mail.")));
|
||||
|
||||
$output .= theme_invoke("theme_item_list", $items);
|
||||
$output .= theme("theme_item_list", $items);
|
||||
|
||||
$block["subject"] = t("Log in");
|
||||
$block["content"] = "<div style=\"{ white-space: nowrap; }\">$output</div>";
|
||||
|
@ -356,10 +356,10 @@ function user_block($op = "list", $delta = 0) {
|
|||
break;
|
||||
case 1:
|
||||
if ($user->uid) {
|
||||
$content[] = theme_invoke("theme_item_list", module_invoke_all("link", "menu.create"));
|
||||
$content[] = theme_invoke("theme_item_list", module_invoke_all("link", "menu.view"));
|
||||
$content[] = theme_invoke("theme_item_list", module_invoke_all("link", "menu.settings"));
|
||||
$content[] = theme_invoke("theme_item_list", module_invoke_all("link", "menu.misc"));
|
||||
$content[] = theme("theme_item_list", module_invoke_all("link", "menu.create"));
|
||||
$content[] = theme("theme_item_list", module_invoke_all("link", "menu.view"));
|
||||
$content[] = theme("theme_item_list", module_invoke_all("link", "menu.settings"));
|
||||
$content[] = theme("theme_item_list", module_invoke_all("link", "menu.misc"));
|
||||
|
||||
$output = implode($content, "<br />");
|
||||
|
||||
|
@ -375,7 +375,7 @@ function user_block($op = "list", $delta = 0) {
|
|||
$items[] = l((strlen($account->name) > 15 ? substr($account->name, 0, 15) . '...' : $account->name), "user/view/$account->uid");
|
||||
}
|
||||
|
||||
$output = theme_invoke("theme_item_list", $items);
|
||||
$output = theme("theme_item_list", $items);
|
||||
|
||||
$block["subject"] = t("Who's new");
|
||||
$block["content"] = $output;
|
||||
|
@ -611,7 +611,7 @@ function user_login($edit = array(), $msg = "") {
|
|||
*/
|
||||
|
||||
if ($error) {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -714,7 +714,7 @@ function user_pass($edit = array()) {
|
|||
|
||||
// Display error message if necessary.
|
||||
if ($error) {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -836,7 +836,7 @@ function user_register($edit = array()) {
|
|||
}
|
||||
else {
|
||||
if ($error) {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -953,7 +953,7 @@ function user_edit($edit = array()) {
|
|||
}
|
||||
|
||||
if ($error) {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
|
||||
if (!$edit) {
|
||||
|
@ -1114,7 +1114,7 @@ function user_page() {
|
|||
|
||||
/*** Administrative features ***********************************************/
|
||||
|
||||
function user_conf_options() {
|
||||
function user_settings() {
|
||||
$output .= form_select(t("Public registrations"), "user_register", variable_get("user_register", 1), array(t("Only site administrators can create new user accounts."), t("Visitors can create accounts and no administrator approval is required."), t("Visitors can create accounts but administrator approval is required.")));
|
||||
$output .= form_textfield(t("Password words"), "user_password", variable_get("user_password", "foo,bar,guy,neo,tux,moo,sun,asm,dot,god,axe,geek,nerd,fish,hack,star,mice,warp,moon,hero,cola,girl,fish,java,perl,boss,dark,sith,jedi,drop,mojo"), 55, 256, t("A comma separated list of short words that can be concatenated to generate human-readable passwords."));
|
||||
$output .= form_select(t("Remember authenticated users"), "user_remember", variable_get("user_remember", 0), array(t("Let the user decide whether he should be logged out when leaving the site."), t("Authenticated users are not logged out upon leaving the site."), t("Authenticated users are logged out upon leaving the site.")));
|
||||
|
@ -1156,7 +1156,7 @@ function user_admin_create($edit = array()) {
|
|||
else {
|
||||
|
||||
if ($error) {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
|
||||
$output .= form_textfield(t("Username"), "name", $edit["name"], 30, 55, t("Provide the username of the new account."));
|
||||
|
@ -1420,7 +1420,7 @@ function user_admin_edit($edit = array()) {
|
|||
$output .= status(t("your user information changes have been saved."));
|
||||
}
|
||||
else {
|
||||
$output .= theme_invoke("theme_error", $error);
|
||||
$output .= theme("theme_error", $error);
|
||||
}
|
||||
}
|
||||
else if ($op == t("Delete account")) {
|
||||
|
|
|
@ -32,7 +32,7 @@ function watchdog_link($type) {
|
|||
}
|
||||
}
|
||||
|
||||
function watchdog_conf_options() {
|
||||
function watchdog_settings() {
|
||||
$period = array(3600 => format_interval(3600), 10800 => format_interval(10800), 21600 => format_interval(21600), 32400 => format_interval(32400), 43200 => format_interval(43200), 86400 => format_interval(86400), 172800 => format_interval(172800), 259200 => format_interval(259200), 604800 => format_interval(604800), 1209600 => format_interval(1209600), 2419200 => format_interval(2419200), 1000000000 => t("Never"));
|
||||
$output .= form_select(t("Discard entries older than"), "watchdog_clear", variable_get("watchdog_clear", 604800), $period, t("The time watchdog entries should be kept. Older entries will be automatically discarded. Requires crontab."));
|
||||
return $output;
|
||||
|
|
|
@ -32,7 +32,7 @@ function watchdog_link($type) {
|
|||
}
|
||||
}
|
||||
|
||||
function watchdog_conf_options() {
|
||||
function watchdog_settings() {
|
||||
$period = array(3600 => format_interval(3600), 10800 => format_interval(10800), 21600 => format_interval(21600), 32400 => format_interval(32400), 43200 => format_interval(43200), 86400 => format_interval(86400), 172800 => format_interval(172800), 259200 => format_interval(259200), 604800 => format_interval(604800), 1209600 => format_interval(1209600), 2419200 => format_interval(2419200), 1000000000 => t("Never"));
|
||||
$output .= form_select(t("Discard entries older than"), "watchdog_clear", variable_get("watchdog_clear", 604800), $period, t("The time watchdog entries should be kept. Older entries will be automatically discarded. Requires crontab."));
|
||||
return $output;
|
||||
|
|
Loading…
Reference in New Issue