mirror of
https://github.com/slawkens/myaac.git
synced 2025-10-14 01:34:55 +02:00
Merge branch 'develop' into feature/recaptcha-v3-plus-login
This commit is contained in:
42
templates/kathrine/javascript.php
Normal file
42
templates/kathrine/javascript.php
Normal file
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
$menus = get_template_menus();
|
||||
|
||||
function get_template_pages($category) {
|
||||
global $menus;
|
||||
|
||||
$ret = array();
|
||||
foreach($menus[$category] as $menu) {
|
||||
$ret[] = $menu['link'];
|
||||
}
|
||||
|
||||
return $ret;
|
||||
}
|
||||
?>
|
||||
var category = '<?php
|
||||
if(strpos(URI, 'subtopic=') !== false) {
|
||||
$tmp = array($_REQUEST['subtopic']);
|
||||
}
|
||||
else {
|
||||
$tmp = URI;
|
||||
if(empty($tmp)) {
|
||||
$tmp = array('news');
|
||||
}
|
||||
else {
|
||||
$tmp = explode('/', URI);
|
||||
}
|
||||
}
|
||||
|
||||
if(in_array($tmp[0], get_template_pages(MENU_CATEGORY_NEWS)))
|
||||
echo 'news';
|
||||
elseif(in_array($tmp[0], get_template_pages(MENU_CATEGORY_LIBRARY)))
|
||||
echo 'library';
|
||||
elseif(in_array($tmp[0], get_template_pages(MENU_CATEGORY_COMMUNITY)))
|
||||
echo 'community';
|
||||
elseif(in_array($tmp[0], array_merge(get_template_pages(MENU_CATEGORY_ACCOUNT), array('account'))))
|
||||
echo 'account';
|
||||
elseif(in_array($tmp[0], get_template_pages(MENU_CATEGORY_SHOP)))
|
||||
echo 'shops';
|
||||
else {
|
||||
echo 'news';
|
||||
}
|
||||
?>';
|
@@ -1,7 +1,7 @@
|
||||
<div id="News">
|
||||
<div class="NewsHeadline">
|
||||
<div class="NewsHeadlineBackground" style="background-image:url({{template_path }}/images/news/newsheadline_background.gif)">
|
||||
<img src="{{ template_path }}/images/news/icon_{{ icon }}.gif" class="NewsHeadlineIcon" />
|
||||
<img src="{{ constant('BASE_URL') }}images/news/icon_{{ icon }}.gif" class="NewsHeadlineIcon" />
|
||||
<div class="NewsHeadlineDate">{{ date|date(config.news_date_format) }} - </div>
|
||||
<div class="NewsHeadlineText">{{ title }}</div>
|
||||
{% if author is not empty %}
|
||||
@@ -22,4 +22,4 @@
|
||||
</tr>
|
||||
{% endif %}
|
||||
</table>
|
||||
<br/>
|
||||
<br/>
|
||||
|
@@ -13,45 +13,7 @@ defined('MYAAC') or die('Direct access not allowed!');
|
||||
</script>
|
||||
<script type="text/javascript" src="tools/basic.js"></script>
|
||||
<script type="text/javascript">
|
||||
<?php
|
||||
$menus = get_template_menus();
|
||||
|
||||
function get_template_pages($category) {
|
||||
global $menus;
|
||||
|
||||
$ret = array();
|
||||
foreach($menus[$category] as $menu) {
|
||||
$ret[] = $menu['link'];
|
||||
}
|
||||
|
||||
return $ret;
|
||||
}
|
||||
?>
|
||||
var category = '<?php
|
||||
if(strpos(URI, 'subtopic=') !== false) {
|
||||
$tmp = array($_REQUEST['subtopic']);
|
||||
}
|
||||
else {
|
||||
$tmp = URI;
|
||||
if(empty($tmp)) {
|
||||
$tmp = array('news');
|
||||
}
|
||||
else {
|
||||
$tmp = explode('/', URI);
|
||||
}
|
||||
}
|
||||
|
||||
if(in_array($tmp[0], get_template_pages(MENU_CATEGORY_NEWS)))
|
||||
echo 'news';
|
||||
elseif(in_array($tmp[0], get_template_pages(MENU_CATEGORY_LIBRARY)))
|
||||
echo 'library';
|
||||
elseif(in_array($tmp[0], get_template_pages(MENU_CATEGORY_COMMUNITY)))
|
||||
echo 'community';
|
||||
elseif(in_array($tmp[0], array_merge(get_template_pages(MENU_CATEGORY_ACCOUNT), array('account'))))
|
||||
echo 'account';
|
||||
elseif(in_array($tmp[0], get_template_pages(MENU_CATEGORY_SHOP)))
|
||||
echo 'shops';
|
||||
?>';
|
||||
<?php require 'javascript.php'; ?>
|
||||
</script>
|
||||
<?php echo template_place_holder('head_end'); ?>
|
||||
</head>
|
||||
|
@@ -33,7 +33,9 @@
|
||||
<td>
|
||||
<table style="float: left; width: 370px;" cellpadding="0" cellspacing="0" >
|
||||
<tr>
|
||||
<td class="LabelV" ><span{% if error is not null %} class="red"{% endif %}>Account {{ account }}:</span></td>
|
||||
<td class="LabelV">
|
||||
<span{% if error is not null %} class="red"{% endif %}>{{ account_login_by }}:</span>
|
||||
</td>
|
||||
<td><input type="text" name="account_login" size="35" maxlength="30" autofocus /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
@@ -1,3 +1,6 @@
|
||||
:focus {
|
||||
outline: -webkit-focus-ring-color dotted 1px;
|
||||
}
|
||||
body {
|
||||
margin: 0px;
|
||||
padding: 0px;
|
||||
|
@@ -1,5 +1,3 @@
|
||||
<?php
|
||||
|
||||
$twig->display('networks.html.twig', array(
|
||||
'topPlayers' => getTopPlayers(5)
|
||||
));
|
||||
$twig->display('networks.html.twig');
|
||||
|
@@ -46,7 +46,7 @@
|
||||
{% for player in topPlayers %}
|
||||
<div style="text-align:left"><a href="{{ getPlayerLink(player['name'], false) }} " class="topfont {% if player['online'] %}online{% else %}offline{% endif %}">
|
||||
{% if config.online_outfit %}
|
||||
<img style="position:absolute;margin-top:{% if player.looktype in [75, 266, 302] %}-20px;margin-left:-0px;{% else %}-45px;margin-left:-25px;{% endif %}" src="{{ player.outfit }}" alt="player outfit"/>
|
||||
<img style="position:absolute;margin-top:{% if player.looktype in config.outfit_images_wrong_looktypes %}-20px;margin-left:-0px;{% else %}-45px;margin-left:-25px;{% endif %}" src="{{ player.outfit }}" alt="player outfit"/>
|
||||
{% endif %}
|
||||
<span style="color: #CCC; margin-left: 40px">{{ player['rank'] }} - </span>
|
||||
{{ player['name'] }}
|
||||
|
@@ -1,22 +1,20 @@
|
||||
{% if config['network_facebook'] != '' or config['network_twitter'] != '' %}
|
||||
<div id="NetworksBox" class="Themebox" style="background-image:url({{ template_path }}/images/themeboxes/networks/networksbox.png);">
|
||||
{% if config['network_facebook'] is not empty %}
|
||||
<div id="FacebookBlock">
|
||||
<div id="FacebookLikeBox">
|
||||
<div class="fb-like-box fb_iframe_widget" data-href="https://www.facebook.com/{{ config['network_facebook'] }}" data-width="175" data-height="180" data-show-faces="true" data-stream="false" data-border-color="none" data-header="false" fb-xfbml-state="rendered">
|
||||
<span style="vertical-align: bottom; width: 181px; height: 180px;">
|
||||
</span>
|
||||
<span style="vertical-align: bottom; width: 181px; height: 180px;"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div id="FacebookSendBox">
|
||||
<div class="fb-send fb_iframe_widget" data-href="https://www.facebook.com/{{ config['network_facebook'] }}" data-width="50" data-height="20" fb-xfbml-state="rendered">
|
||||
<span style="vertical-align: bottom; width: 50px; height: 20px;">
|
||||
</span>
|
||||
<span style="vertical-align: bottom; width: 50px; height: 20px;"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div id="FacebookLikes">
|
||||
<div class="fb-like fb_edge_widget_with_comment fb_iframe_widget" data-href="https://www.facebook.com/{{ config['network_facebook'] }}" data-send="false" data-width="225" data-show-faces="false" fb-xfbml-state="rendered">
|
||||
<span style="height: 28px; width: 225px;">
|
||||
</span>
|
||||
<span style="height: 28px; width: 225px;"></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -29,3 +27,4 @@
|
||||
{% endif %}
|
||||
<div class="Bottom" style="background-image:url({{ template_path }}/images/general/box-bottom.gif);"></div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
@@ -1,42 +1,23 @@
|
||||
<?php
|
||||
//require '../../common.php';
|
||||
$text = $_GET['t'];
|
||||
if(strlen($text) > 100) // max limit
|
||||
$text = '';
|
||||
|
||||
//$text = $_GET['text'];
|
||||
/*
|
||||
$page_file = BASE . 'pages/' . PAGE . '.php';
|
||||
if(!@file_exists($page_file))
|
||||
{
|
||||
$page_file = BASE . 'pages/custom/' . PAGE . '.php';
|
||||
if(!@file_exists($page_file))
|
||||
die('Page does not exists.');
|
||||
}
|
||||
*/
|
||||
//$file = 'images/header/headline-' . PAGE . '.gif';
|
||||
//if(!file_exists($file))
|
||||
//{
|
||||
if(strlen($_GET['t']) > 100) // max limit
|
||||
$_GET['t'] = '';
|
||||
// set font path
|
||||
putenv('GDFONTPATH=' . __DIR__);
|
||||
|
||||
// set font path
|
||||
putenv('GDFONTPATH=' . __DIR__);
|
||||
// create image
|
||||
$image = imagecreatetruecolor(250, 28);
|
||||
|
||||
// create image
|
||||
$image = imagecreatetruecolor(250, 28);
|
||||
// make the background transparent
|
||||
imagecolortransparent($image, imagecolorallocate($image, 0, 0, 0));
|
||||
|
||||
// make the background transparent
|
||||
imagecolortransparent($image, imagecolorallocate($image, 0, 0, 0));
|
||||
// set text
|
||||
$font = getenv('GDFONTPATH') . DIRECTORY_SEPARATOR . 'martel.ttf';
|
||||
imagettftext($image, 18, 0, 4, 20, imagecolorallocate($image, 240, 209, 164), $font, utf8_decode($text));
|
||||
|
||||
// set text
|
||||
imagettftext($image, 18, 0, 4, 20, imagecolorallocate($image, 240, 209, 164), 'martel.ttf', utf8_decode($_GET['t']));
|
||||
// header mime type
|
||||
header('Content-type: image/gif');
|
||||
|
||||
// header mime type
|
||||
header('Content-type: image/gif');
|
||||
|
||||
// save image
|
||||
imagegif($image/*, $file*/);
|
||||
//}
|
||||
|
||||
// output image
|
||||
//header('Content-type: image/gif');
|
||||
//readfile($file);
|
||||
?>
|
||||
// output image to browser
|
||||
imagegif($image);
|
||||
|
@@ -12,10 +12,18 @@ if(isset($config['boxes']))
|
||||
<link href="<?php echo $template_path; ?>/basic.css" rel="stylesheet" type="text/css" />
|
||||
<script type="text/javascript" src="tools/basic.js"></script>
|
||||
<script type="text/javascript" src="<?php echo $template_path; ?>/ticker.js"></script>
|
||||
|
||||
<?php if(!empty($config['network_twitter'])): ?>
|
||||
<script id="twitter-wjs" src="<?php echo $template_path; ?>/js/twitter.js"></script>
|
||||
<script id="facebook-jssdk" async src="<?php echo $template_path; ?>/js/facebook.js"></script>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if(!empty($config['network_facebook'])): ?>
|
||||
<script id="facebook-jssdk" async src="https://connect.facebook.net/en_US/all.js"></script>
|
||||
<link href="<?php echo $template_path; ?>/css/facebook.css" rel="stylesheet" type="text/css">
|
||||
<?php endif; ?>
|
||||
|
||||
<script type="text/javascript">
|
||||
var menus = '';
|
||||
var loginStatus="<?php echo ($logged ? 'true' : 'false'); ?>";
|
||||
<?php
|
||||
if(PAGE !== 'news') {
|
||||
@@ -105,8 +113,8 @@ if(isset($config['boxes']))
|
||||
}
|
||||
}
|
||||
|
||||
var menu = new Array();
|
||||
menu[0] = new Object();
|
||||
var menu = [];
|
||||
menu[0] = {};
|
||||
var unloadhelper = false;
|
||||
|
||||
// load the menu and set the active submenu item by using the variable 'activeSubmenuItem'
|
||||
@@ -114,8 +122,9 @@ if(isset($config['boxes']))
|
||||
{
|
||||
document.getElementById("submenu_"+activeSubmenuItem).style.color = "white";
|
||||
document.getElementById("ActiveSubmenuItemIcon_"+activeSubmenuItem).style.visibility = "visible";
|
||||
if(self.name.lastIndexOf("&") == -1) {
|
||||
self.name = "news=1&account=0&community=0&library=0&forum=0<?php if($config['gifts_system']) echo '&shops=0'; ?>&";
|
||||
menus = localStorage.getItem('menus');
|
||||
if(menus.lastIndexOf("&") === -1) {
|
||||
menus = "news=1&account=0&community=0&library=0&forum=0<?php if($config['gifts_system']) echo '&shops=0'; ?>&";
|
||||
}
|
||||
FillMenuArray();
|
||||
InitializeMenu();
|
||||
@@ -132,13 +141,13 @@ if(isset($config['boxes']))
|
||||
// store the values of the variable 'self.name' in the array menu
|
||||
function FillMenuArray()
|
||||
{
|
||||
while(self.name.length > 0 ){
|
||||
var mark1 = self.name.indexOf("=");
|
||||
var mark2 = self.name.indexOf("&");
|
||||
var menuItemName = self.name.substr(0, mark1);
|
||||
menu[0][menuItemName] = self.name.substring(mark1 + 1, mark2);
|
||||
self.name = self.name.substr(mark2 + 1, self.name.length);
|
||||
}
|
||||
while(menus.length > 0 ){
|
||||
var mark1 = menus.indexOf("=");
|
||||
var mark2 = menus.indexOf("&");
|
||||
var menuItemName = menus.substr(0, mark1);
|
||||
menu[0][menuItemName] = menus.substring(mark1 + 1, mark2);
|
||||
menus = menus.substr(mark2 + 1, menus.length);
|
||||
}
|
||||
}
|
||||
|
||||
// hide or show the corresponding submenus
|
||||
@@ -160,16 +169,17 @@ if(isset($config['boxes']))
|
||||
}
|
||||
}
|
||||
|
||||
// reconstruct the variable "self.name" out of the array menu
|
||||
function SaveMenuArray()
|
||||
{
|
||||
var stringSlices = "";
|
||||
var temp = "";
|
||||
for(menuItemName in menu[0]) {
|
||||
stringSlices = menuItemName + "=" + menu[0][menuItemName] + "&";
|
||||
temp = temp + stringSlices;
|
||||
}
|
||||
self.name = temp;
|
||||
var stringSlices = "";
|
||||
var temp = "";
|
||||
|
||||
for(menuItemName in menu[0]) {
|
||||
stringSlices = menuItemName + "=" + menu[0][menuItemName] + "&";
|
||||
temp = temp + stringSlices;
|
||||
}
|
||||
|
||||
localStorage.setItem('menus', temp);
|
||||
}
|
||||
|
||||
// onClick open or close submenus
|
||||
@@ -369,7 +379,7 @@ foreach($config['menu_categories'] as $id => $cat) {
|
||||
}
|
||||
?>
|
||||
<script type="text/javascript">
|
||||
InitializePage();
|
||||
InitializePage();
|
||||
</script>
|
||||
</div>
|
||||
<div id="ContentColumn">
|
||||
|
File diff suppressed because one or more lines are too long
@@ -13,7 +13,7 @@
|
||||
{% for ticker in tickers %}
|
||||
<div id="TickerEntry-{{ i }}" class="Row" onclick='TickerAction("TickerEntry-{{ i }}")'>
|
||||
<div class="{% if (i / 2) matches '/^\\d+$/' %}Odd{% else %}Even{% endif %}">
|
||||
<div class="NewsTickerIcon" style="background-image: url({{ template_path }}/images/news/icon_{{ ticker.icon }}_small.gif);"></div>
|
||||
<div class="NewsTickerIcon" style="background-image: url({{ constant('BASE_URL') }}images/news/icon_{{ ticker.icon }}_small.gif);"></div>
|
||||
<div id="TickerEntry-{{ i }}-Button" class="NewsTickerExtend" style="background-image: url({{ template_path }}/images/general/plus.gif);"></div>
|
||||
<div class="NewsTickerText">
|
||||
<span class="NewsTickerDate">{{ ticker.date|date("j M Y") }} -</span>
|
||||
@@ -45,4 +45,4 @@
|
||||
<div class="Border_1" style="background-image: url({{ template_path }}/images/content/border-1.gif);"></div>
|
||||
<div class="CornerWrapper-b"><div class="Corner-bl" style="background-image: url({{ template_path }}/images/content/corner-bl.gif);"></div></div>
|
||||
<div class="CornerWrapper-b"><div class="Corner-br" style="background-image: url({{ template_path }}/images/content/corner-br.gif);"></div></div>
|
||||
</div>
|
||||
</div>
|
||||
|
Reference in New Issue
Block a user