mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-11-05 23:09:04 +00:00
cleaned up formatting and added custom.css
This commit is contained in:
parent
1d155268d2
commit
473703c19f
11 changed files with 116 additions and 99 deletions
|
@ -1,7 +1,7 @@
|
|||
<?php
|
||||
class Helpers{
|
||||
|
||||
static public function loadTemplate( $template, $vars = array (), $forcelibrender = false )
|
||||
static public function loadTemplate( $template, $vars = array (), $forcelibrender = false )
|
||||
{
|
||||
global $AMS_LIB;
|
||||
global $SITEBASE;
|
||||
|
@ -44,35 +44,35 @@ class Helpers{
|
|||
foreach ( $variables[$template] as $key => $value ){
|
||||
$smarty -> assign( $key, $value );
|
||||
}
|
||||
if($vars['permission'] == 1){
|
||||
$inherited = "layout_admin.tpl";
|
||||
}else{
|
||||
$inherited = "layout_user.tpl";
|
||||
}
|
||||
//extends:' . $inherited .'|register.tpl
|
||||
$smarty -> display( $template.'.tpl' );
|
||||
if( $vars['permission'] == 1 ){
|
||||
$inherited = "layout_admin.tpl";
|
||||
}else{
|
||||
$inherited = "layout_user.tpl";
|
||||
}
|
||||
// extends:' . $inherited .'|register.tpl
|
||||
$smarty -> display( $template . '.tpl' );
|
||||
}
|
||||
|
||||
static public function create_folders(){
|
||||
global $AMS_LIB;
|
||||
global $SITEBASE;
|
||||
$arr = array( $AMS_LIB . '/ingame_templates/',
|
||||
$AMS_LIB . '/configs',
|
||||
$AMS_LIB . '/cache',
|
||||
$SITEBASE . '/cache/',
|
||||
$SITEBASE . '/templates/',
|
||||
$SITEBASE . '/templates_c/',
|
||||
$SITEBASE . '/configs'
|
||||
);
|
||||
foreach ( $arr as & $value ){
|
||||
$arr = array( $AMS_LIB . '/ingame_templates/',
|
||||
$AMS_LIB . '/configs',
|
||||
$AMS_LIB . '/cache',
|
||||
$SITEBASE . '/cache/',
|
||||
$SITEBASE . '/templates/',
|
||||
$SITEBASE . '/templates_c/',
|
||||
$SITEBASE . '/configs'
|
||||
);
|
||||
foreach ( $arr as & $value ){
|
||||
if ( !file_exists( $value ) ){
|
||||
mkdir( $value );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
static public function check_if_game_client()
|
||||
static public function check_if_game_client()
|
||||
{
|
||||
// if HTTP_USER_AGENT is not set then its ryzom core
|
||||
if ( !isset( $_SERVER['HTTP_USER_AGENT'] ) ){
|
||||
|
|
|
@ -1,11 +1,10 @@
|
|||
<?php
|
||||
class Sql{
|
||||
|
||||
public function db_query( $query, $values = array() )
|
||||
public function db_query( $query, $values = array() )
|
||||
{
|
||||
echo "tst";
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -230,4 +230,3 @@ class Users{
|
|||
}
|
||||
}
|
||||
|
||||
|
|
@ -3,6 +3,6 @@
|
|||
// Base include file for library functions for AMS
|
||||
// ***********************************************
|
||||
function __autoload( $className ){
|
||||
require_once 'autoload/' . strtolower ($className) . '.php';
|
||||
}
|
||||
require_once 'autoload/' . strtolower ( $className ) . '.php';
|
||||
}
|
||||
|
||||
|
|
|
@ -64,7 +64,7 @@ if ( ( $user == "success" ) and ( $pass == "success" ) and ( $cpass == "success"
|
|||
$pageElements['TAC_ERROR'] = 'TRUE';
|
||||
}
|
||||
if ( helpers :: check_if_game_client() ){
|
||||
helpers :: loadtemplate( '../../ams_lib/ingame_templates/register.phtml', $pageElements );
|
||||
helpers :: loadtemplate( '../../ams_lib/ingame_templates/register.phtml', $pageElements );
|
||||
}else{
|
||||
helpers :: loadtemplate( 'templates/register.phtml', $pageElements );
|
||||
}
|
||||
|
|
17
code/ryzom/tools/server/ryzom_ams/www/html/css/custom.css
Normal file
17
code/ryzom/tools/server/ryzom_ams/www/html/css/custom.css
Normal file
|
@ -0,0 +1,17 @@
|
|||
.login-header
|
||||
{
|
||||
height:190px;
|
||||
}
|
||||
|
||||
.brand img
|
||||
{
|
||||
height:100%;
|
||||
margin-bottom:-18px;
|
||||
margin-top:-15px;
|
||||
width:100%;
|
||||
}
|
||||
|
||||
#for-is-ajax
|
||||
{
|
||||
display:none;
|
||||
}
|
|
@ -1,12 +1,12 @@
|
|||
<?php
|
||||
function add_user(){
|
||||
|
||||
// add user locally here
|
||||
// add user locally here
|
||||
$return = users :: add_user();
|
||||
return $return;
|
||||
}
|
||||
return $return;
|
||||
}
|
||||
|
||||
function checkUser(){
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
@ -6,18 +6,18 @@ require( '../../ams_lib/libinclude.php' );
|
|||
if ( isset( $_POST["function"] ) ){
|
||||
require( "inc/" . $_POST["function"] . ".php" );
|
||||
$return = $_POST["function"]();
|
||||
}
|
||||
}
|
||||
|
||||
function loadpage ( $page ){
|
||||
require_once( 'autoload/' . $page . '.php' );
|
||||
}
|
||||
}
|
||||
|
||||
$page = 'home';
|
||||
if ( isset( $_GET["page"] ) ){
|
||||
$page = $_GET["page"];
|
||||
}
|
||||
}
|
||||
|
||||
//temporary set permission to 1 which = admin mode
|
||||
$return = array('permission' => 1, 'no_visible_elements' => 'TRUE');
|
||||
// temporary set permission to 1 which = admin mode
|
||||
$return = array( 'permission' => 1, 'no_visible_elements' => 'TRUE' );
|
||||
|
||||
helpers :: loadTemplate( $page , $return );
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
$(document).ready(function(){
|
||||
//themes, change CSS with JS
|
||||
//default theme(CSS) is cerulean, change it if needed
|
||||
var current_theme = $.cookie('current_theme')==null ? 'spacelab' :$.cookie('current_theme');
|
||||
var current_theme = $.cookie('current_theme')==null ? 'cerulean' :$.cookie('current_theme');
|
||||
switch_theme(current_theme);
|
||||
|
||||
$('#themes a[data-value="'+current_theme+'"]').find('i').addClass('icon-ok');
|
||||
|
|
|
@ -52,6 +52,8 @@
|
|||
<!-- The fav icon -->
|
||||
<!--<link rel="shortcut icon" href="img/favicon.ico">-->
|
||||
|
||||
<!--custom css file-->
|
||||
<link href="css/custom.css" rel="stylesheet">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
|
Loading…
Reference in a new issue