diff --git a/mojotrollz/autoload.inc.php b/mojotrollz/autoload.inc.php index 3ce5a8f..82d87c0 100644 --- a/mojotrollz/autoload.inc.php +++ b/mojotrollz/autoload.inc.php @@ -1,6 +1,6 @@ "); + window.location.reload(); } else { $('.help-block').html("Login not successfull. User & Password combination wrong.") } diff --git a/mojotrollz/page/page_mojotrollz.php b/mojotrollz/page/page_mojotrollz.php index 4618379..e8c7c2f 100644 --- a/mojotrollz/page/page_mojotrollz.php +++ b/mojotrollz/page/page_mojotrollz.php @@ -3,11 +3,15 @@ class page_mojotrollz extends \SYSTEM\API\api_default { public static function default_page(){ + if(\SYSTEM\SECURITY\Security::isLoggedIn()){ + return new user_default();} return new default_page();} + //Default Start public static function page_default_start(){ return new default_start();} + //Wizard public static function page_wizard_details(){ return new wizard_details();} @@ -32,18 +36,33 @@ class page_mojotrollz extends \SYSTEM\API\api_default { public static function page_wizard_toolbar($last,$next){ return new wizard_toolbar($last,$next);} - public static function page_user_news(){ - return new user_news();} - - public static function page_user_guild(){ - return new user_guild();} - - public static function page_user_bank(){ - return new user_bank();} - - public static function page_user_logout(){ - return new user_logout();} - + //Get Info Data public static function page_default_info($id){ return new default_info($id);} + + //User Area + public static function page_user_start(){ + if(!\SYSTEM\SECURITY\Security::isLoggedIn()){ + throw new ERROR("You need to be logged in to view this ressource.");} + return new user_start();} + + public static function page_user_character(){ + if(!\SYSTEM\SECURITY\Security::isLoggedIn()){ + throw new ERROR("You need to be logged in to view this ressource.");} + return new user_character();} + + public static function page_user_menu(){ + if(!\SYSTEM\SECURITY\Security::isLoggedIn()){ + throw new ERROR("You need to be logged in to view this ressource.");} + return new user_menu();} + + public static function page_user_database(){ + if(!\SYSTEM\SECURITY\Security::isLoggedIn()){ + throw new ERROR("You need to be logged in to view this ressource.");} + return new user_database();} + + public static function page_user_logout(){ + if(!\SYSTEM\SECURITY\Security::isLoggedIn()){ + throw new ERROR("You need to be logged in to view this ressource.");} + return new user_logout();} } diff --git a/mojotrollz/page/user_character/user_character.php b/mojotrollz/page/user_character/user_character.php new file mode 100644 index 0000000..93c5598 --- /dev/null +++ b/mojotrollz/page/user_character/user_character.php @@ -0,0 +1,8 @@ +'. + ''. + ''. + ''. + ''. + ''. + ''. + ''. + ''; + } + + private function css (){ + return ''. + ''. + ''; + } + + public function html(){ + $vars = array(); + $vars['js'] = $this->js(); + $vars['css'] = $this->css(); + $vars['PICPATH'] = \SYSTEM\CONFIG\config::get(\SYSTEM\CONFIG\config_ids::SYS_CONFIG_PATH_BASEURL).'api.php?call=files&cat=default_page&id='; + $vars['copyright'] = ''; + $vars['inprint'] = ''; + $vars = array_merge($vars, \SYSTEM\locale::getStrings(DBD\locale_string::VALUE_CATEGORY_MAINPAGE), + \SYSTEM\locale::getStrings(DBD\locale_string::VALUE_CATEGORY_WOW_SERVERINFO), + \SYSTEM\locale::getStrings(DBD\locale_string::VALUE_CATEGORY_BASIC)); + return SYSTEM\PAGE\replace::replaceFile(SYSTEM\SERVERPATH(new PPAGE(),'user_default/user_default.tpl'), $vars); + + } +} \ No newline at end of file diff --git a/mojotrollz/page/user_default/user_default.tpl b/mojotrollz/page/user_default/user_default.tpl new file mode 100644 index 0000000..c81ff34 --- /dev/null +++ b/mojotrollz/page/user_default/user_default.tpl @@ -0,0 +1,36 @@ + + +
+