make front page a variable, and add support for default values in config->get

git-svn-id: file:///home/shish/svn/shimmie2/trunk@51 7f39781d-f577-437e-ae19-be835c7a54ca
This commit is contained in:
shish
2007-05-01 13:40:48 +00:00
parent f6fdc13101
commit 3d2ea2a842
3 changed files with 16 additions and 14 deletions

View File

@@ -246,6 +246,7 @@ function send_event($event) {
\* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
function _get_query_parts() {
global $config;
if(isset($_GET["q"])) {
$path = $_GET["q"];
}
@@ -253,7 +254,7 @@ function _get_query_parts() {
$path = $_SERVER["PATH_INFO"];
}
else {
$path = "index/1";
$path = $config->get_string('front_page', 'index');
}
while(strlen($path) > 0 && $path[0] == '/') {