Commit 3b7425ae authored by Kjartan's avatar Kjartan

- added a new configuration option that lets you set various index.php

  variables.

  Example: set site_frontpage to "node" and site_frontpage_extra to
  "$meta = 'news'" and only nodes with that meta tag will be displayed on
   your main page.

  This requires some internal knowledge of how the various modules work
  and what settings can be passed to <module>_page() functions.
parent 83c5209c
......@@ -5,6 +5,7 @@
page_header();
eval(variable_get("site_frontpage_extra", "") .";");
$function = variable_get("site_frontpage", "node") ."_page";
$function();
......
......@@ -38,6 +38,7 @@ function system_view_options() {
$output .= form_textfield("Password words", "account_words", variable_get("account_words", "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, "Words used in the creation of passwords. Comma seperated list.");
foreach (module_list() as $name) { if (module_hook($name, "page")) $pages[$name] = $name; }
$output .= form_select("Default front page", "site_frontpage", variable_get("site_frontpage", "node"), $pages, "The default front page.");
$output .= form_textfield("Extra front page settings", "site_frontpage_extra", variable_get("site_frontpage_extra", ""), 55, 128, "Lets you define additonal variables for the main page in PHP.");
$output .= "<hr />\n";
// caching:
......
......@@ -38,6 +38,7 @@ function system_view_options() {
$output .= form_textfield("Password words", "account_words", variable_get("account_words", "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, "Words used in the creation of passwords. Comma seperated list.");
foreach (module_list() as $name) { if (module_hook($name, "page")) $pages[$name] = $name; }
$output .= form_select("Default front page", "site_frontpage", variable_get("site_frontpage", "node"), $pages, "The default front page.");
$output .= form_textfield("Extra front page settings", "site_frontpage_extra", variable_get("site_frontpage_extra", ""), 55, 128, "Lets you define additonal variables for the main page in PHP.");
$output .= "<hr />\n";
// caching:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment