X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fhome.php;h=d45b13ed5fb4e21ca02bd8d7296bbabb0a879741;hb=28ebbe38d6f987c91b508d384e24ba15c2dad06b;hp=d89b47bc20dc7eb9c7da68de61975fdae021d562;hpb=2370a3f89b5f10e6c98edf019fe25d98eb58d401;p=friendica.git diff --git a/mod/home.php b/mod/home.php index d89b47bc20..d45b13ed5f 100644 --- a/mod/home.php +++ b/mod/home.php @@ -3,23 +3,30 @@ if(! function_exists('home_init')) { function home_init(&$a) { - if(x($_SESSION,'authenticated') && (x($_SESSION,'uid'))) { - if($a->user['nickname']) + if(local_user() && ($a->user['nickname'])) goaway( $a->get_baseurl() . "/profile/" . $a->user['nickname'] ); - else - goaway( $a->get_baseurl() . "/profile/" . $_SESSION['uid'] ); - } - $a->page['htmlhead'] .= "get_baseurl() . "/profile/%s" . "\" />\r\n"; - + + $a->page['htmlhead'] .= "get_baseurl() . "/profile/%s" . "\" />\r\n"; }} if(! function_exists('home_content')) { function home_content(&$a) { - $a->page['footer'] .= "
Powered by mistpark
"; - $o .= '

Welcome' . ((x($a->config,'sitename')) ? " to {$a->config['sitename']}" : "" ) . '

'; + + $o = ''; + + if(x($_SESSION,'theme')) + unset($_SESSION['theme']); + + $o .= '

' . ((x($a->config,'sitename')) ? t("Welcome to ").$a->config['sitename'] : "" ) . '

'; + if(file_exists('home.html')) + $o .= file_get_contents('home.html'); + $o .= login(($a->config['register_policy'] == REGISTER_CLOSED) ? 0 : 1); + + call_hooks("home_content",$o); + return $o; -}} \ No newline at end of file +}}