The first release of the refactored version

It's still a work in progress, there are a lot of things that will
change in the final release
This commit is contained in:
iopietro
2018-09-16 17:22:39 +02:00
parent f032523e1c
commit 62d6e19ee9
3503 changed files with 90956 additions and 35819 deletions
+4
View File
@@ -0,0 +1,4 @@
<Files ~ "\.tpl$">
Order allow,deny
Deny from all
</Files>
+190
View File
@@ -0,0 +1,190 @@
<?php
############################################################
## DO NOT REMOVE THIS NOTICE ##
## MADE BY TTMTT ##
## FIX BY RONIX ##
## TRAVIANZ ##
############################################################
if($session->access != ADMIN && ($session->alliance == 0 || ($session->alliance > 0 && !$opt['opt5']))) $alliance->redirect($_GET);
?>
<script language="JavaScript" type="text/javascript">
function showCheckList() {
bid = document.getElementById('bid');
if(bid.value == 2) {
document.getElementById('conf_list').className = '';
document.getElementById('ally_list').className = '';
document.getElementById('user_list').className = 'hide';
}
else if (bid.value == 3) {
document.getElementById('conf_list').className = 'hide';
document.getElementById('ally_list').className = 'hide';
document.getElementById('user_list').className = '';
}
else {
document.getElementById('conf_list').className = 'hide';
document.getElementById('ally_list').className = 'hide';
document.getElementById('user_list').className = 'hide';
}
}
</script>
<script language="JavaScript" type="text/javascript">
function addRow(element_id) {
// element_id: user_list, ally_list
liste = document.getElementById(element_id);
liste = liste.getElementsByTagName('tbody')[0];
var anzahl_trs = liste.getElementsByTagName('tr').length;
var num_fields = anzahl_trs;
var num_last_tr = anzahl_trs -1;
lastTR = liste.getElementsByTagName('tr')[num_last_tr];
lastTD = lastTR.getElementsByTagName('td')[2];
lastIMG = lastTD.getElementsByTagName('img')[0];
lastTD.removeChild(lastIMG);
newTR = document.createElement('tr');
newTD1 = document.createElement('td');
newTD2 = document.createElement('td');
newTD3 = document.createElement('td');
newTR.appendChild(newTD1);
newTR.appendChild(newTD2);
newTR.appendChild(newTD3);
liste.appendChild(newTR);
var html_input_1 = '<input class="text" type="text" ';
if(element_id == 'ally_list') {
newTD1.className = 'ally';
newTD2.className = 'tag';
newTD3.className = 'ad';
newTD1.innerHTML = html_input_1 + 'id="allys_by_id_'+num_fields+'" class="text" maxlength="15" name="allys_by_id['+num_fields+']" onkeyup="checkInputs('+num_fields+',\'allys\')">';
newTD2.innerHTML = html_input_1 + 'id="allys_by_name_'+num_fields+'" class="text" maxlength="15" name="allys_by_name['+num_fields+']" onkeyup="checkInputs('+num_fields+',\'allys\')">';
}
if(element_id == 'user_list') {
newTD1.className = 'id';
newTD2.className = 'pla';
newTD3.className = 'ad';
newTD1.innerHTML = html_input_1 + 'id="users_by_id_'+num_fields+'" class="text" maxlength="15" name="users_by_id['+num_fields+']" onkeyup="checkInputs('+num_fields+',\'users\')">';
newTD2.innerHTML = html_input_1 + 'id="users_by_name_'+num_fields+'" class="text" maxlength="50" name="users_by_name['+num_fields+']" onkeyup="checkInputs('+num_fields+',\'users\')">';
}
newTD3.innerHTML = '<img class="add" src="img/x.gif" title="add" alt="add" onclick="addRow(\''+element_id+'\')">';
}
</script>
<script language="JavaScript" type="text/javascript">
function checkInputs(id, typ) {
id_field = document.getElementById(typ+'_by_id_'+id);
name_field = document.getElementById(typ+'_by_name_'+id);
//alert(id_field.value);
//alert(name_field.value);
if (id_field.value != '' && id_field.disabled == false) {
name_field.disabled = true;
name_field.style.border = '1px solid #999';
}
else {
name_field.disabled = false;
name_field.style.border = '1px solid #71D000';
}
if (name_field.value != '' && name_field.disabled == false) {
id_field.disabled = true;
id_field.style.border = '1px solid #999';
}
else {
id_field.disabled = false;
id_field.style.border = '1px solid #71D000';
}
}
</script><form method="post" action="allianz.php?s=2">
<input type="hidden" name="new" value="1">
<input type="hidden" name="newforum" value="1">
<input type="hidden" name="admin" value="1">
<table cellpadding="1" cellspacing="1" id="new_forum"><thead>
<tr>
<th colspan="2">New forum</th>
</tr>
</thead><tbody>
<tr>
<th>Forum name</th>
<td><input class="text" type="text" name="u1" value="" maxlength="20"></td>
</tr>
<tr>
<th>Description</th>
<td><input class="text" type="text" name="u2" value="" maxlength="38"></td>
</tr>
<tr>
<th>Forum type</th>
<td><select class="dropdown" id="bid" name="bid" onchange="showCheckList();"><?php if($session->access == ADMIN){ ?><option value="1">Public Forum</option><?php }else{ ?><option value="2">Confederation Forum</option><option value="0" selected>Alliance Forum</option><option value="3">Closed Forum</option><?php } ?></select></td>
</tr>
</tbody></table>
<?php if($session->access != ADMIN){ ?>
<table cellpadding="1" cellspacing="1" id="ally_list"><thead>
<tr>
<th colspan="3">Open for more alliances</th>
</tr>
<tr>
<td>Alliance ID</td>
<td>Tag:</td>
<td>Add</td>
</tr>
</thead><tbody>
<tr>
<td class="ally">
<input class="text" type="text" id="allys_by_id_0" maxlength="15" name="allys_by_id[0]" onkeyup="checkInputs(0,'allys');" />
</td>
<td class="tag">
<input class="text" type="text" id="allys_by_name_0" maxlength="15" name="allys_by_name[0]" onkeyup="checkInputs(0,'allys');" />
</td>
<td class="ad">
<img class="add" src="img/x.gif" title="add" alt="add" onclick="addRow('ally_list')" />
</td>
</tr>
</table><table cellpadding="1" cellspacing="1" id="user_list"><thead>
<tr>
<th colspan="3">Open forum for the following players</th>
</tr>
<tr>
<td>User ID</td>
<td>Name:</td>
<td>Add</td>
</tr>
</thead><tbody>
<tr>
<td class="id">
<input class="text" type="text" id="users_by_id_0" maxlength="15" name="users_by_id[0]" onkeyup="checkInputs(0,'users');" />
</td>
<td class="pla">
<input class="text" type="text" id="users_by_name_0" maxlength="50" name="users_by_name[0]" onkeyup="checkInputs(0,'users');" />
</td>
<td class="ad">
<img class="add" src="img/x.gif" title="add" alt="add" onclick="addRow('user_list')" />
</td>
</tr>
</tbody></table>
<script language="JavaScript" type="text/javascript">
showCheckList();
</script>
<?php } ?>
<p class="btn"><input type="image" id="fbtn_ok" value="ok" name="s1" class="dynamic_img" src="img/x.gif" alt="OK" /></p></form>
+310
View File
@@ -0,0 +1,310 @@
<?php
// ###########################################################
// # DO NOT REMOVE THIS NOTICE ##
// # MADE BY TTMTT ##
// # FIX BY RONIX ##
// # TRAVIANZ ##
// ###########################################################
$topic_id = $_GET['tid'];
$post_id = $_GET['pod'];
$topics = reset($database->ShowTopic($topic_id));
$posts = $database->ShowPostEdit($post_id);
//Check if we're modifying a valid post
if(empty($topics) || empty($posts)) $alliance->redirect($_GET);
$title = stripslashes($topics['title']);
foreach($posts as $pos){
$poss = stripslashes($pos['post']);
$poss = preg_replace('/\[message\]/', '', $poss);
$poss = preg_replace('/\[\/message\]/', '', $poss);
$owner = $pos['owner'];
}
?>
<form method="post" name="post"
action="allianz.php?s=2&fid2=<?php echo $topics['cat']; ?>&tid=<?php echo $topics['id']; ?>">
<input type="hidden" name="s" value="2"> <input type="hidden"
name="pod" value="<?php echo $_GET['pod']; ?>"> <input type="hidden"
type="hidden" name="editpost" value="1">
<table cellpadding="1" cellspacing="1" id="edit_post">
<thead>
<tr>
<th colspan="2">Edit answer</th>
</tr>
</thead>
<tbody>
<tr>
<th>Thread</th>
<td><?php echo $title; ?></td>
</tr>
<tr>
<td></td>
<td>
<div bbArea="text" id="text_container" name="text_container">
<div id="text_toolbar" name="text_toolbar">
<a href="javascript:void(0);" bbType="d" bbTag="b">
<div title="bold" alt="bold" class="bbButton bbBold"></div>
</a> <a href="javascript:void(0);" bbType="d" bbTag="i">
<div title="italic" alt="italic" class="bbButton bbItalic"></div>
</a> <a href="javascript:void(0);" bbType="d" bbTag="u">
<div title="underlined" alt="underlined"
class="bbButton bbUnderscore"></div>
</a> <a href="javascript:void(0);" bbType="d" bbTag="alliance">
<div title="Alliance" alt="Alliance" class="bbButton bbAlliance"></div>
</a> <a href="javascript:void(0);" bbType="d" bbTag="player">
<div title="Player" alt="Player" class="bbButton bbPlayer"></div>
</a> <a href="javascript:void(0);" bbType="d" bbTag="coor">
<div title="Coordinates" alt="Coordinates"
class="bbButton bbCoordinate"></div>
</a> <a href="javascript:void(0);" bbType="d" bbTag="report">
<div title="Report" alt="Report" class="bbButton bbReport"></div>
</a> <a href="javascript:void(0);" bbWin="resources"
id="text_resourceButton">
<div title="Resources" alt="Resources"
class="bbButton bbResource"></div>
</a> <a href="javascript:void(0);" bbWin="smilies"
id="text_smilieButton">
<div title="Smilies" alt="Smilies" class="bbButton bbSmilie"></div>
</a> <a href="javascript:void(0);" bbWin="troops"
id="text_troopButton">
<div title="Troops" alt="Troops" class="bbButton bbTroop"></div>
</a> <a href="javascript:void(0);" id="text_previewButton"
bbArea="text">
<div title="Preview" alt="Preview" class="bbButton bbPreview"></div>
</a>
<div class="clear"></div>
<div id="text_toolbarWindows">
<div id="text_resources" name="text_resources">
<a href="javascript:void(0);" bbType="o" bbTag="lumber"><img
src="img/x.gif" class="r1" title="Wood" alt="Wood" /></a> <a
href="javascript:void(0);" bbType="o" bbTag="clay"><img
src="img/x.gif" class="r2" title="Clay" alt="{$smarty.const.CLAY}" /></a> <a
href="javascript:void(0);" bbType="o" bbTag="iron"><img
src="img/x.gif" class="r3" title="Iron" alt="{$smarty.const.IRON}" /></a> <a
href="javascript:void(0);" bbType="o" bbTag="crop"><img
src="img/x.gif" class="r4" title="Crop" alt="{$smarty.const.CROP}" /></a>
</div>
<div id="text_smilies" name="text_smilies">
<a href="javascript:void(0);" bbType="s" bbTag="*aha*"><img
class="smiley aha" src="img/x.gif" alt="*aha*" title="*aha*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*angry*"><img
class="smiley angry" src="img/x.gif" alt="*angry*"
title="*angry*" /></a><a href="javascript:void(0);" bbType="s"
bbTag="*cool*"><img class="smiley cool" src="img/x.gif"
alt="*cool*" title="*cool*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*cry*"><img
class="smiley cry" src="img/x.gif" alt="*cry*" title="*cry*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*cute*"><img
class="smiley cute" src="img/x.gif" alt="*cute*"
title="*cute*" /></a><a href="javascript:void(0);" bbType="s"
bbTag="*depressed*"><img class="smiley depressed"
src="img/x.gif" alt="*depressed*" title="*depressed*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*eek*"><img
class="smiley eek" src="img/x.gif" alt="*eek*" title="*eek*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*ehem*"><img
class="smiley ehem" src="img/x.gif" alt="*ehem*"
title="*ehem*" /></a><a href="javascript:void(0);" bbType="s"
bbTag="*emotional*"><img class="smiley emotional"
src="img/x.gif" alt="*emotional*" title="*emotional*" /></a><a
href="javascript:void(0);" bbType="s" bbTag=":D"><img
class="smiley grin" src="img/x.gif" alt=":D" title=":D" /></a><a
href="javascript:void(0);" bbType="s" bbTag=":)"><img
class="smiley happy" src="img/x.gif" alt=":)" title=":)" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*hit*"><img
class="smiley hit" src="img/x.gif" alt="*hit*" title="*hit*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*hmm*"><img
class="smiley hmm" src="img/x.gif" alt="*hmm*" title="*hmm*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*hmpf*"><img
class="smiley hmpf" src="img/x.gif" alt="*hmpf*"
title="*hmpf*" /></a><a href="javascript:void(0);" bbType="s"
bbTag="*hrhr*"><img class="smiley hrhr" src="img/x.gif"
alt="*hrhr*" title="*hrhr*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*huh*"><img
class="smiley huh" src="img/x.gif" alt="*huh*" title="*huh*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*lazy*"><img
class="smiley lazy" src="img/x.gif" alt="*lazy*"
title="*lazy*" /></a><a href="javascript:void(0);" bbType="s"
bbTag="*love*"><img class="smiley love" src="img/x.gif"
alt="*love*" title="*love*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*nocomment*"><img
class="smiley nocomment" src="img/x.gif" alt="*nocomment*"
title="*nocomment*" /></a><a href="javascript:void(0);"
bbType="s" bbTag="*noemotion*"><img class="smiley noemotion"
src="img/x.gif" alt="*noemotion*" title="*noemotion*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*notamused*"><img
class="smiley notamused" src="img/x.gif" alt="*notamused*"
title="*notamused*" /></a><a href="javascript:void(0);"
bbType="s" bbTag="*pout*"><img class="smiley pout"
src="img/x.gif" alt="*pout*" title="*pout*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*redface*"><img
class="smiley redface" src="img/x.gif" alt="*redface*"
title="*redface*" /></a><a href="javascript:void(0);"
bbType="s" bbTag="*rolleyes*"><img class="smiley rolleyes"
src="img/x.gif" alt="*rolleyes*" title="*rolleyes*" /></a><a
href="javascript:void(0);" bbType="s" bbTag=":("><img
class="smiley sad" src="img/x.gif" alt=":(" title=":(" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*shy*"><img
class="smiley shy" src="img/x.gif" alt="*shy*" title="*shy*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*smile*"><img
class="smiley smile" src="img/x.gif" alt="*smile*"
title="*smile*" /></a><a href="javascript:void(0);" bbType="s"
bbTag="*tongue*"><img class="smiley tongue" src="img/x.gif"
alt="*tongue*" title="*tongue*" /></a><a
href="javascript:void(0);" bbType="s" bbTag="*veryangry*"><img
class="smiley veryangry" src="img/x.gif" alt="*veryangry*"
title="*veryangry*" /></a><a href="javascript:void(0);"
bbType="s" bbTag="*veryhappy*"><img class="smiley veryhappy"
src="img/x.gif" alt="*veryhappy*" title="*veryhappy*" /></a><a
href="javascript:void(0);" bbType="s" bbTag=";)"><img
class="smiley wink" src="img/x.gif" alt=";)" title=";)" /></a>
</div>
<div id="text_troops" name="text_troops">
<a href="javascript:void(0);" bbType="o" bbTag="tid1"><img
class="unit u1" src="img/x.gif" title="Legionnaire"
alt="Legionnaire" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid2"><img class="unit u2" src="img/x.gif"
title="Praetorian" alt="Praetorian" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid3"><img
class="unit u3" src="img/x.gif" title="Imperian"
alt="Imperian" /></a><a href="javascript:void(0);" bbType="o"
bbTag="tid4"><img class="unit u4" src="img/x.gif"
title="Equites Legati" alt="Equites Legati" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid5"><img
class="unit u5" src="img/x.gif" title="Equites Imperatoris"
alt="Equites Imperatoris" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid6"><img class="unit u6" src="img/x.gif"
title="Equites Caesaris" alt="Equites Caesaris" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid7"><img
class="unit u7" src="img/x.gif" title="Ram" alt="Ram" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid8"><img
class="unit u8" src="img/x.gif" title="Fire Catapult"
alt="Fire Catapult" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid9"><img class="unit u9" src="img/x.gif"
title="Senator" alt="Senator" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid10"><img
class="unit u10" src="img/x.gif" title="Settler" alt="Settler" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid11"><img
class="unit u11" src="img/x.gif" title="Maceman" alt="Maceman" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid12"><img
class="unit u12" src="img/x.gif" title="Spearman"
alt="Spearman" /></a><a href="javascript:void(0);" bbType="o"
bbTag="tid13"><img class="unit u13" src="img/x.gif"
title="Axeman" alt="Axeman" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid14"><img
class="unit u14" src="img/x.gif" title="Scout" alt="Scout" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid15"><img
class="unit u15" src="img/x.gif" title="Paladin" alt="Paladin" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid16"><img
class="unit u16" src="img/x.gif" title="Teutonic Knight"
alt="Teutonic Knight" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid17"><img class="unit u17" src="img/x.gif"
title="Ram" alt="Ram" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid18"><img class="unit u18" src="img/x.gif"
title="Catapult" alt="Catapult" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid19"><img
class="unit u19" src="img/x.gif" title="Chieftain"
alt="Chieftain" /></a><a href="javascript:void(0);" bbType="o"
bbTag="tid20"><img class="unit u20" src="img/x.gif"
title="Settler" alt="Settler" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid21"><img
class="unit u21" src="img/x.gif" title="Phalanx" alt="Phalanx" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid22"><img
class="unit u22" src="img/x.gif" title="Swordsman"
alt="Swordsman" /></a><a href="javascript:void(0);" bbType="o"
bbTag="tid23"><img class="unit u23" src="img/x.gif"
title="Pathfinder" alt="Pathfinder" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid24"><img
class="unit u24" src="img/x.gif" title="Theutates Thunder"
alt="Theutates Thunder" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid25"><img class="unit u25" src="img/x.gif"
title="Druidrider" alt="Druidrider" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid26"><img
class="unit u26" src="img/x.gif" title="Haeduan" alt="Haeduan" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid27"><img
class="unit u27" src="img/x.gif" title="Battering Ram"
alt="Battering Ram" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid28"><img class="unit u28" src="img/x.gif"
title="Trebuchet" alt="Trebuchet" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid29"><img
class="unit u29" src="img/x.gif" title="Chief" alt="Chief" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid30"><img
class="unit u30" src="img/x.gif" title="Settler" alt="Settler" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid31"><img
class="unit u31" src="img/x.gif" title="Rat" alt="Rat" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid32"><img
class="unit u32" src="img/x.gif" title="Spider" alt="Spider" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid33"><img
class="unit u33" src="img/x.gif" title="Snake" alt="Snake" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid34"><img
class="unit u34" src="img/x.gif" title="Bat" alt="Bat" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid35"><img
class="unit u35" src="img/x.gif" title="Wild Boar"
alt="Wild Boar" /></a><a href="javascript:void(0);" bbType="o"
bbTag="tid36"><img class="unit u36" src="img/x.gif"
title="Wolf" alt="Wolf" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid37"><img class="unit u37" src="img/x.gif"
title="Bear" alt="Bear" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid38"><img class="unit u38" src="img/x.gif"
title="Crocodile" alt="Crocodile" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid39"><img
class="unit u39" src="img/x.gif" title="Tiger" alt="Tiger" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid40"><img
class="unit u40" src="img/x.gif" title="Elephant"
alt="Elephant" /></a><a href="javascript:void(0);" bbType="o"
bbTag="tid41"><img class="unit u41" src="img/x.gif"
title="Pikeman" alt="Pikeman" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid42"><img
class="unit u42" src="img/x.gif" title="Thorned Warrior"
alt="Thorned Warrior" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid43"><img class="unit u43" src="img/x.gif"
title="Guardsman" alt="Guardsman" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid44"><img
class="unit u44" src="img/x.gif" title="Birds of Prey"
alt="Birds of Prey" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid45"><img class="unit u45" src="img/x.gif"
title="Axerider" alt="Axerider" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid46"><img
class="unit u46" src="img/x.gif" title="Natarian Knight"
alt="Natarian Knight" /></a><a href="javascript:void(0);"
bbType="o" bbTag="tid47"><img class="unit u47" src="img/x.gif"
title="War Elephant" alt="War Elephant" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid48"><img
class="unit u48" src="img/x.gif" title="Ballista"
alt="Ballista" /></a><a href="javascript:void(0);" bbType="o"
bbTag="tid49"><img class="unit u49" src="img/x.gif"
title="Natarian Emperor" alt="Natarian Emperor" /></a><a
href="javascript:void(0);" bbType="o" bbTag="tid50"><img
class="unit u50" src="img/x.gif" title="Settler" alt="Settler" /></a><a
href="javascript:void(0);" bbType="o" bbTag="hero"><img
class="unit uhero" src="img/x.gif" title="Hero" alt="Hero" /></a>
</div>
</div>
</div>
<div class="line bbLine"></div>
<textarea id="text" name="text"><?php echo $poss; ?></textarea>
<div id="text_preview" name="text_preview"></div>
</div> <script>
var bbEditor = new BBEditor("text");
</script>
</td>
</tr>
</tbody>
</table>
<p class="btn">
<input type="image" id="fbtn_ok" value="ok" name="s1"
class="dynamic_img" src="img/x.gif" alt="OK" />
</form>
</p>
<span style="color: #DD0000"><b>Warning:</b> you can't use the values <b>[message]</b>
or <b>[/message]</b> in your post because it can cause problem with
bbcode system.</span>
+102
View File
@@ -0,0 +1,102 @@
<?php
// ###########################################################
// # DO NOT REMOVE THIS NOTICE ##
// # MADE BY TTMTT ##
// # FIX BY RONIX ##
// # TRAVIANZ ##
// ###########################################################
$opt = $database->getAlliPermissions($session->uid, $aid);
$displayarray = $database->getUserArray($session->uid, 1);
$forumcat = $database->ForumCat(htmlspecialchars($displayarray['alliance']));
$forumcat = array_merge(!empty($forumcat) ? $forumcat : [],
$session->sharedForums['alliance'],
$session->sharedForums['confederation'],
$session->sharedForums['closed']);
$countArray = [$database->countForums(0, $session->alliance) + count($session->sharedForums['alliance']),
$database->countForums(1, -1),
$database->countForums(2, $session->alliance) + count($session->sharedForums['confederation']),
$database->countForums(3, $session->alliance) + count($session->sharedForums['closed'])];
$forumArea = ["Alliance Forum(s)", "Public Forum(s)", "Confederation Forum(s)", "Closed Forum(s)"];
foreach($countArray as $index => $count){
if($session->alliance > 0 || ($session->alliance == 0 && $index == 1)){
?>
<table cellpadding="1" cellspacing="1" id="public">
<thead>
<tr>
<th colspan="4"><?php echo $forumArea[$index]; ?></th>
</tr>
<tr>
<td></td>
<td>Forum name</td>
<td>&nbsp;Threads&nbsp;</td>
<td>&nbsp;Last post&nbsp;</td>
</tr>
</thead>
<tbody>
<?php
if($count == 0) echo "<tr><td colspan=\"4\" style=\"text-align: center\">".NO_FORUMS_YET."</td></tr>";
}
foreach($forumcat as $arr){
if($arr['forum_area'] != $index || ($session->alliance == 0 && $arr['forum_area'] != 1)) continue;
$checkArray = ['aid' => $aid, 'alliance' => $arr['alliance'], 'forum_perm' => $opt['opt5'],
'owner' => $arr['owner'], 'admin' => $_GET['admin'], 'forum_owner' => $arr['owner']];
$countop = $database->CountCat($arr['id']);
$lpost = $owner = "";
if($countop > 0){
$ltopic = $database->LastTopic($arr['id']);
foreach($ltopic as $las){
$lpos = $database->LastPost($las['id']);
if($database->CheckLastTopic($arr['id'])){
//If there are no posts yet, show the topic
if($database->CheckLastPost($las['id']) == 0){
$lpost = date('d.m.y H:i a', $las['date']);
$owner = $database->getUserArray($las['owner'], 1);
}else{
foreach($lpos as $pos){
$lpost = date('d.m.y H:i a', $pos['date']);
$owner = $database->getUserArray($pos['owner'], 1);
}
}
}
}
}
echo '<tr><td class="ico">';
if(Alliance::canAct($checkArray)){
echo '<a class="up_arr" href="allianz.php?s=2&fid='.$arr['id'].'&res=1&admin=pos" title="To top">
<img src="img/x.gif" alt="To top" /></a><a class="edit" href="allianz.php?s=2&idf='.$arr['id'].'&admin=editforum" title="edit">
<img src="img/x.gif" alt="edit" /></a><br /><a class="down_arr" href="allianz.php?s=2&fid='.$arr['id'].'&res=0&admin=pos" title="To bottom">
<img src="img/x.gif" alt="To bottom" /></a><a class="fdel" href="allianz.php?s=2&idf='.$arr['id'].'&admin=delforum" onClick="return confirm(\'confirm delete?\');" title="delete">
<img src="img/x.gif" alt="delete" /></a>';
}
else echo '<img class="folder" src="img/x.gif" title="Thread without new posts" alt="Thread without new posts">';
echo '</td><td class="tit">
<a href="allianz.php?s=2&fid='.$arr['id'].'&pid='.$aid.'" title="'.stripslashes($arr['forum_name']).'">'.stripslashes($arr['forum_name']).'</a><br />'.stripslashes($arr['forum_des']).'</td>
<td class="cou">'.$countop.'</td>
<td class="last">'.$lpost.'</span><span><br />';
if(!empty($owner)){
echo '<a href="spieler.php?uid='.$owner['id'].'">'.$owner['username'].'</a> <img class="latest_reply" src="img/x.gif" alt="Show last post" title="Show last post" />';
}
echo '</td>
</tr>';
}
?>
</tbody>
</table>
<?php } ?>
<p>
<?php
if(isset($opt['opt5']) && $opt['opt5'] == 1 || $session->access == ADMIN){
echo '<a href="allianz.php?s=2&admin=newforum"><img id="fbtn_newforum" class="dynamic_img" src="img/x.gif" alt="New forum" /></a>';
echo '<a href="allianz.php?s='.$ids.((isset($_GET['admin']) && !empty($_GET['admin']) && $_GET['admin'] == "switch_admin") ? "" : "&admin=switch_admin").'" title="Toggle Admin mode"><img class="switch_admin dynamic_img" src="img/x.gif" alt="Toggle Admin mode" /></a>';
}
?>
</p>
+49
View File
@@ -0,0 +1,49 @@
<?php
############################################################
## DO NOT REMOVE THIS NOTICE ##
## MADE BY TTMTT ##
## FIX BY RONIX ##
## TRAVIANZ ##
############################################################
$topicID = $_GET['idt'];
$showTopic = reset($database->ShowTopic($topicID));
$forumData = reset($database->ForumCatEdit($showTopic['cat']));
$title = stripslashes($showTopic['title']);
$canBeMoved = $forumData['forum_area'] == 1 && $session->access == 9;
?>
<form method="post" action="allianz.php?s=2&fid=<?php echo $_GET['fid']; ?>">
<input type="hidden" name="s" value="2">
<input type="hidden" name="tid" value="<?php echo $topicID; ?>">
<?php if(!$canBeMoved){ ?>
<input type="hidden" name="fid" value="<?php echo $showTopic['cat']; ?>">
<?php } ?>
<input type="hidden" name="edittopic" value="1">
<table cellpadding="1" cellspacing="1" id="edit_topic"><thead>
<tr>
<td colspan="2">Edit topic</td>
</tr>
</thead><tbody>
<tr>
<th>Thread</th>
<td><input class="text" type="Text" name="thema" value="<?php echo $title; ?>" maxlength="35"></td>
</tr>
<?php if($canBeMoved){?>
<tr>
<td>Move topic</td>
<td><select class="dropdown" name="fid">
<?php
$show_cat = $database->ForumCat($forumData['alliance']);
foreach($show_cat as $cats) {
if($session->access == 9 && $cats['owner'] != $session->uid) continue;
if($cats['id'] == $_GET['fid']) echo '<option value="'.$cats['id'].'" selected>'.stripslashes($cats['forum_name']).'</option>';
else echo '<option value="'.$cats['id'].'">'.stripslashes($cats['forum_name']).'</option>';
}
?>
</select></td>
</tr>
<?php } ?>
</tbody></table>
<p class="btn"><button id="fbtn_ok" value="ok" name="s1" class="trav_buttons"> OK </button></p></form>
+91
View File
@@ -0,0 +1,91 @@
<?php
############################################################
## DO NOT REMOVE THIS NOTICE ##
## MADE BY TTMTT ##
## FIX BY RONIX ##
## TRAVIANZ ##
############################################################
$cat_id = $_GET['fid'];
$forumInfo = $database->ForumCatEdit($cat_id);
//Check if we're viewing a valid forum
if(empty($forumInfo)) $alliance->redirect($_GET);
$forumData = reset($forumInfo);
$CatName = stripslashes($forumData['forum_name']);
$opt = $database->getAlliPermissions($session->uid, $aid);
$ChckTopic = $database->CheckCatTopic($cat_id);
$Topics = array_merge($database->ForumCatTopicStick($cat_id), $database->ForumCatTopic($cat_id));
?>
<h4><a href="allianz.php?s=2">Alliance</a> -> <a href="allianz.php?s=2&fid=<?php echo $cat_id; ?>"><?php echo $CatName; ?></a></h4><table cellpadding="1" cellspacing="1" id="topics"><thead>
<tr>
<th colspan="4"><?php echo $CatName; ?></th>
</tr>
<tr>
<td></td>
<td>Threads</td>
<td>Replies</td>
<td>Last post</td>
</tr></thead><tbody>
<?php
if($ChckTopic){
foreach($Topics as $arrs) {
$checkArray = ['aid' => $aid, 'alliance' => $arrs['alliance'], 'forum_perm' => $opt['opt5'],
'owner' => $arrs['owner'], 'admin' => $_GET['admin'], 'forum_owner' => $forumData['owner']];
$CountPosts = $database->CountPost($arrs['id']);
$lposts = $database->LastPost($arrs['id']);
foreach($lposts as $post) {
}
if($database->CheckLastPost($arrs['id'])){
$post_dates = date('d.m.y, H:i a',$post['date']);
$owner_topics = $database->getUserArray($post['owner'],1);
}else{
$post_dates = date('d.m.y, H:i a',$arrs['date']);
$owner_topics = $database->getUserArray($arrs['owner'],1);
}
echo '<tr><td class="ico">';
if(Alliance::canAct($checkArray))
{
if($database->CheckCloseTopic($arrs['id']) == 1){
$locks = '<a class="unlock" href="?s=2&fid='.$_GET['fid'].'&idt='.$arrs['id'].'&admin=unlock" title="open topic"><img src="img/x.gif" alt="open topic" /></a>';
}else{
$locks = '<a class="lock" href="?s=2&fid='.$_GET['fid'].'&idt='.$arrs['id'].'&admin=lock" title="close topic"><img src="img/x.gif" alt="close topic" /></a>';
}
if($arrs['stick'] == 1){
$pin = '<a class="unpin" href="?s=2&fid='.$_GET['fid'].'&idt='.$arrs['id'].'&admin=unpin" title="Unstick topic"><img src="img/x.gif" alt="Unstick topic" /></a>';
}else{
$pin = '<a class="pin" href="?s=2&fid='.$_GET['fid'].'&idt='.$arrs['id'].'&admin=pin" title="Stick topic"><img src="img/x.gif" alt="Stick topic" /></a>';
}
echo $locks.'<a class="edit" href="?s=2&fid='.$_GET['fid'].'&idt='.$arrs['id'].'&admin=edittopic" title="edit"><img src="img/x.gif" alt="edit" /></a><br />'.$pin.'<a class="fdel" href="?s=2&fid='.$_GET['fid'].'&idt='.$arrs['id'].'&admin=deltopic" title="delete"><img src="img/x.gif" alt="delete" onClick="return confirm(\'confirm delete?\');" /></a>';
}elseif($arrs['close'] == 1){
echo '<img class="folder_'.($arrs['stick'] == 1 ? 'sticky_' : '').'lock" src="img/x.gif" alt="Closed Thread without new posts" title="Closed Thread without new posts" />';
}else{
echo '<img class="folder'.($arrs['stick'] == 1 ? '_sticky' : '').'" src="img/x.gif" alt="'.($arrs['stick'] == 1 ? 'Important ' : '').'Thread without new posts" title="'.($arrs['stick'] == 1 ? 'Important ' : '').'Thread without new posts" />';
}
echo '</td>
<td class="tit"><a href="allianz.php?s=2&fid2='.$arrs['cat'].'&tid='.$arrs['id'].'">'.stripslashes($arrs['title']).'</a><br></td>
<td class="cou">'.$CountPosts.'</td>
<td class="last">'.$post_dates.'<br /><a href="spieler.php?uid='.$arrs['owner'].'">'.$owner_topics['username'].'</a> <a href="allianz.php?s=2&fid2='.$arrs['cat'].'&pid='.$aid.'&tid='.$arrs['id'].'"><img class="latest_reply" src="img/x.gif" alt="Show last post" title="Show last post" /></a>
</td></tr>';
}
}else{
echo '<tr>
<td class="none" colspan="4">No topic yet</td>
</tr>';
}
?>
</tbody></table><p>
<?php
if($forumData['forum_area'] != 3 || ($forumData['forum_area'] == 3 && $opt['opt5'] == 1)){
?>
<a href="allianz.php?s=2&pid=<?php echo $aid; ?>&fid=<?php echo $cat_id; ?>&ac=newtopic"><img id="fbtn_post" class="dynamic_img" src="img/x.gif" alt="Post new thread" /></a>
<?php
echo '<a href="allianz.php?s=2&fid='.$cat_id.((isset($_GET['admin']) && !empty($_GET['admin']) && $_GET['admin'] == "switch_admin") ? "" : "&admin=switch_admin").'" title="Toggle Admin mode"><img class="switch_admin dynamic_img" src="img/x.gif" alt="Toggle Admin mode" /></a>';
}
?>
</p>
File diff suppressed because one or more lines are too long
+186
View File
@@ -0,0 +1,186 @@
<?php
// ###########################################################
// # DO NOT REMOVE THIS NOTICE ##
// # MADE BY TTMTT ##
// # FIX BY RONIX ##
// # TRAVIANZ ##
// ###########################################################
$tid = $_GET['tid'];
$topics = $database->ShowTopic($tid);
//Check if we're viewing a valid thread
if(empty($topics)) $alliance->redirect($_GET);
$posts = $database->ShowPost($tid);
foreach($topics as $arr){
$cat_id = $arr['cat'];
$owner = $database->getUserArray($arr['owner'], 1);
$forumData = reset($database->ForumCatEdit($cat_id));
$CatName = stripslashes($forumData['forum_name']);
$allianceinfo = $database->getAlliance($owner['alliance']);
}
$date = date('d.m.y H:i a', $arr['date']);
$varray = $database->getProfileVillages($arr['owner']);
$totalpop = 0;
foreach($varray as $vil) $totalpop += $vil['pop'];
$countAu = $database->CountTopic($arr['owner']);
$tribeArray = [ROMANS, TEUTONS, GAULS];
$displayarray = $database->getUserArray($arr['owner'], 1);
$trip = $tribeArray[$displayarray['tribe'] - 1];
$input = $arr['post'];
$bbcoded = $input;
include ("GameEngine/BBCode.php");
$bbcode_topic = stripslashes(nl2br($bbcoded));
?>
<h4>
<a href="allianz.php?s=2">Alliance</a> -> <a
href="allianz.php?s=2&fid=<?php echo $arr['cat']; ?>"><?php echo $CatName; ?></a>
</h4>
<table cellpadding="1" cellspacing="1" id="posts">
<thead>
<tr>
<th colspan="2"><?php echo stripslashes($arr['title']); ?></th>
</tr>
<tr>
<td>Author</td>
<td>Message</td>
</tr>
</thead>
<tbody>
<tr>
<td class="pinfo"><a class="name"
href="spieler.php?uid=<?php echo $arr['owner']; ?>"><?php echo $owner['username']; ?></a><br />
<a href="allianz.php?aid=<?php echo $allianceinfo['id']; ?>"><?php echo $allianceinfo['tag']; ?></a><br />
Posts: <?php echo $countAu; ?><br /> <br />
Pop: <?php echo $totalpop; ?><br />
Villages: <?php echo count($varray);?><br />
<?php echo $trip; ?>
</td>
<td class="pcontent"><div class="posted">created: <?php echo $date; ?></div>
<?php
$checkArray = ['aid' => $aid, 'alliance' => $arr['alliance'], 'forum_perm' => $opt['opt5'],
'owner' => $arr['owner'], 'admin' => $_GET['admin'], 'forum_owner' => $forumData['owner']];
if(Alliance::canAct($checkArray)){
echo '<div class="admin"><a class="edit" href="allianz.php?s=2&idt='.$arr['id'].'&admin=editans"><img src="img/x.gif" title="edit" alt="edit" /></a><a class="fdel" href="?s=2&fid='.$arr['cat'].'&idt='.$arr['id'].'&admin=deltopic" onClick="return confirm(\'confirm delete?\');"><img src="img/x.gif" title="delete" alt="delete" /></a></div><br />';
}
?>
<div class="clear dotted"></div>
<div class="text"><?php echo $bbcode_topic; ?></div></td>
</tr>
<?php
if($database->checkSurvey($arr['id'])){
$survey = $database->getSurvey($arr['id']);
if(!$database->checkVote($arr['id'], $session->uid) && ($survey['ends'] > time() || $survey['ends'] == 0)){
?>
<tr>
<td colspan="2"><div style="text-align: center">Survey: <?php echo $survey['title']; ?></div>
<div class="clear dotted"></div>
<form method="post" name="post"
action="allianz.php?s=2&tid=<?php echo $_GET['tid']; ?>">
<table width="100%" border="0" align="left" cellPadding="0"
style="border-collapse: collapse">
<?php
for($i = 1; $i <= 8; $i++){
if(!empty($survey['option'.$i])){
?>
<tr>
<td width="5%"><input class="radio" type="radio" name="vote"
value="<?php echo $i; ?>" /></td>
<td width="95%">
<?php echo $survey['option'.$i]; ?>
</td>
<?php
}
}
?>
</table>
<div class="text">
<input type="hidden" name="fid2"
value="<?php echo $_GET['fid2']; ?>" /> <input type="hidden"
name="tid" value="<?php echo $_GET['tid']; ?>" />
<p class="btn">
<input type="image" id="fbtn_vote" value="ok" name="s1"
class="dynamic_img" src="img/x.gif" alt="Vote" />
</form>
</p>
</div></td>
</tr>
<?php }else{ ?>
<tr>
<td class="pcontent" colspan="2">
<div style="text-align: center">Survey: <?php echo $survey['title']; ?></div>
<div class="clear dotted"></div>
<div class="text">
<?php
$sum = $database->getVoteSum($arr['id']);
for($i = 1; $i <= 8; $i++){
if($survey['option'.$i] != ""){
if($sum > 0) $width = 100 * ($survey['vote'.$i] / $sum);
else $width = 0;
?>
<?php echo $survey['option'.$i]." "; ?><img
src="<?php echo GP_LOCATE; ?>/img/f/c4.gif"
width="<?php echo $width; ?>" /><?php echo " ".$survey['vote'.$i]; ?></br>
<?php
}
}
?>
</div></td>
</tr>
<?php }} ?>
<?php
foreach($posts as $po){
$topic = reset($database->ShowTopic($po['topic']));
$checkArray = ['aid' => $aid, 'alliance' => $topic['alliance'], 'forum_perm' => $opt['opt5'],
'owner' => $po['owner'], 'admin' => $_GET['admin'], 'forum_owner' => $forumData['owner']];
$date = date('d.m.y H:i a', $po['date']);
$countAu = $database->CountTopic($po['owner']);
$varray = $database->getProfileVillages($po['owner']);
$totalpop = 0;
foreach($varray as $vil) $totalpop += $vil['pop'];
$displayarray = $database->getUserArray($po['owner'], 1);
$trip = $tribeArray[$displayarray['tribe'] - 1];
$owner = $database->getUserArray($po['owner'], 1);
$allianceinfo = $database->getAlliance($owner['alliance']);
$input = $po['post'];
include ("GameEngine/BBCode.php");
$bbcode_post = stripslashes(nl2br($bbcoded));
echo '<tr><td class="pinfo"><a class="name" href="spieler.php?uid='.$po['owner'].'">'.$owner['username'].'</a><br /><a href="allianz.php?aid='.$allianceinfo['id'].'">'.$allianceinfo['tag'].'</a><br />
Posts: '.$countAu.'<br />
<br />
Pop: '.$totalpop.'<br />
Villages: '.count($varray).'<br />
'.$trip.'
</td>
<td class="pcontent"><div class="posted">created: '.$date.'</div>';
if(Alliance::canAct($checkArray)){
echo '<div class="admin"><a class="edit" href="allianz.php?s=2&fid='.$topic['cat'].'&tid='.$_GET['tid'].'&pod='.$po['id'].'&admin=editpost"><img src="img/x.gif" title="edit" alt="edit" /></a><a class="fdel" href="?s=2&pod='.$po['id'].'&tid='.$_GET['tid'].'&fid2='.$topic['cat'].'&admin=delpost" onClick="return confirm(\'confirm delete?\');"><img src="img/x.gif" title="delete" alt="delete" /></a></div><br />';
}
echo '<div class="clear dotted"></div><div class="text">'.$bbcode_post.'</div></td>
</tr>';
}
?>
</tbody>
</table>
<div style="margin-top: 15px;">
<?php
if(!$arr['close'] && ($forumData['forum_area'] != 3 || ($forumData['forum_area'] == 3 && $opt['opt5'] == 1))){
echo '<a href="allianz.php?s=2&tid='.$arr['id'].'&ac=newpost"><img id="fbtn_reply" class="dynamic_img"src="img/x.gif" alt="Replies" /></a>';
echo '<a href="allianz.php?s=2&tid='.$arr['id'].((isset($_GET['admin']) && !empty($_GET['admin']) && $_GET['admin'] == "switch_admin") ? "" : "&admin=switch_admin").'" title="Toggle Admin mode"><img class="switch_admin dynamic_img" src="img/x.gif" alt="Toggle Admin mode" /></a>';
}
?>
</div>
File diff suppressed because one or more lines are too long
+193
View File
@@ -0,0 +1,193 @@
<?php
############################################################
## DO NOT REMOVE THIS NOTICE ##
## MADE BY TTMTT ##
## FIX BY RONIX ##
## TRAVIANZ ##
############################################################
$forumData = reset($database->ForumCatEdit($_GET['idf']));
if(empty($forumData) || ($forumData['alliance'] == 0 && $session->access != ADMIN) ||
($forumData['alliance'] > 0 && ($forumData['alliance'] != $session->alliance ||
(!$opt['opt5'] && $session->access != ADMIN)))) $alliance->redirect($_GET);
$users = $alliances = [];
$cat_name = stripslashes($forumData['forum_name']);
$cat_des = stripslashes($forumData['forum_des']);
if(!empty($forumData['display_to_alliances'])) $alliances = explode(',', $forumData['display_to_alliances']);
if(!empty($forumData['display_to_users'])) $users = explode(',', $forumData['display_to_users']);
?>
<script type="text/javascript">
function addRow(element_id) {
// element_id: user_list, ally_list
liste = document.getElementById(element_id);
liste = liste.getElementsByTagName('tbody')[0];
var anzahl_trs = liste.getElementsByTagName('tr').length;
var num_fields = anzahl_trs;
var num_last_tr = anzahl_trs -1;
lastTR = liste.getElementsByTagName('tr')[num_last_tr];
lastTD = lastTR.getElementsByTagName('td')[2];
lastIMG = lastTD.getElementsByTagName('img')[0];
lastTD.removeChild(lastIMG);
newTR = document.createElement('tr');
newTD1 = document.createElement('td');
newTD2 = document.createElement('td');
newTD3 = document.createElement('td');
newTR.appendChild(newTD1);
newTR.appendChild(newTD2);
newTR.appendChild(newTD3);
liste.appendChild(newTR);
var html_input_1 = '<input class="text" type="text" ';
if(element_id == 'ally_list') {
newTD1.className = 'ally';
newTD2.className = 'tag';
newTD3.className = 'ad';
newTD1.innerHTML = html_input_1 + 'id="allys_by_id_'+num_fields+'" class="text" maxlength="8" name="allys_by_id['+num_fields+']" onkeyup="checkInputs('+num_fields+',\'allys\')">';
newTD2.innerHTML = html_input_1 + 'id="allys_by_name_'+num_fields+'" class="text" maxlength="8" name="allys_by_name['+num_fields+']" onkeyup="checkInputs('+num_fields+',\'allys\')">';
}
if(element_id == 'user_list') {
newTD1.className = 'id';
newTD2.className = 'pla';
newTD3.className = 'ad';
newTD1.innerHTML = html_input_1 + 'id="users_by_id_'+num_fields+'" class="text" maxlength="8" name="users_by_id['+num_fields+']" onkeyup="checkInputs('+num_fields+',\'users\')">';
newTD2.innerHTML = html_input_1 + 'id="users_by_name_'+num_fields+'" class="text" maxlength="15" name="users_by_name['+num_fields+']" onkeyup="checkInputs('+num_fields+',\'users\')">';
}
newTD3.innerHTML = '<img class="add" src="img/x.gif" title="add" alt="add" onclick="addRow(\''+element_id+'\')">';
}
</script>
<script language="JavaScript" type="text/javascript">
function checkInputs(id, typ) {
id_field = document.getElementById(typ+'_by_id_'+id);
name_field = document.getElementById(typ+'_by_name_'+id);
//alert(id_field.value);
//alert(name_field.value);
if (id_field.value != '' && id_field.disabled == false) {
name_field.disabled = true;
name_field.style.border = '1px solid #999';
}
else {
name_field.disabled = false;
name_field.style.border = '1px solid #71D000';
}
if (name_field.value != '' && name_field.disabled == false) {
id_field.disabled = true;
id_field.style.border = '1px solid #999';
}
else {
id_field.disabled = false;
id_field.style.border = '1px solid #71D000';
}
}
</script><form method="post" action="allianz.php?s=2">
<input type="hidden" name="s" value="2">
<input type="hidden" name="fid" value="<?php echo $_GET['idf']; ?>">
<input type="hidden" name="editforum" value="1">
<table cellpadding="1" cellspacing="1" id="edit_forum"><thead>
<tr>
<th colspan="2">edit forum</th>
</tr>
</thead><tbody>
<tr>
<th>Forum name</th>
<td><input class="text" type="text" name="u1" value="<?php echo $cat_name; ?>" maxlength="30"></td>
</tr>
<tr>
<th>Description</th>
<td><input class="text" type="text" name="u2" value="<?php echo $cat_des; ?>" maxlength="38"></td>
</tr>
</table>
<?php if($forumData['forum_area'] != 1){ ?>
<table cellpadding="1" cellspacing="1" id="ally_list"><thead>
<tr>
<th colspan="3">Open for more alliances</th>
</tr>
<tr>
<td>Alliance ID</td>
<td>Tag:</td>
<td>Add</td>
</tr>
</thead><tbody>
<?php for($i = 0; $i < count($alliances); $i++){?>
<tr>
<td class="ally">
<input class="text" type="text" id="allys_by_id_<?php echo $i; ?>" disabled="disabled" maxlength="15" name="allys_by_id[<?php echo $i; ?>]" onkeyup="checkInputs(<?php echo $i; ?>,'allys');" />
</td>
<td class="tag">
<input class="text" type="text" id="allys_by_name_<?php echo $i; ?>" value="<?php echo $database->getAlliance($alliances[$i])['tag']; ?>" maxlength="15" name="allys_by_name[<?php echo $i; ?>]" onkeyup="checkInputs(<?php echo $i; ?>,'allys');" />
</td>
<td class="ad"></td>
</tr>
<?php } ?>
<tr>
<td class="ally">
<input class="text" type="text" id="allys_by_id_<?php echo $i; ?>" name="allys_by_id[<?php echo $i; ?>]" maxlength="15" onkeyup="checkInputs(<?php echo $i; ?>,'allys');" />
</td>
<td class="tag">
<input class="text" type="text" id="allys_by_name_<?php echo $i; ?>" name="allys_by_name[<?php echo $i; ?>]" maxlength="15" onkeyup="checkInputs(<?php echo $i; ?>,'allys');" />
</td>
<td class="ad">
<img class="add" src="img/x.gif" title="add" alt="add" onclick="addRow('ally_list')" />
</td>
</tr>
</table><table cellpadding="1" cellspacing="1" id="user_list"><thead>
<tr>
<th colspan="3">Open forum for the following players</th>
</tr>
<tr>
<td>User ID</td>
<td>Name:</td>
<td>Add</td>
</tr>
</thead><tbody>
<?php for($i = 0; $i < count($users); $i++){?>
<tr>
<td class="id">
<input class="text" type="text" id="users_by_id_<?php echo $i; ?>" disabled="disabled" name="users_by_id[<?php echo $i; ?>]" maxlength="15" onkeyup="checkInputs(<?php echo $i; ?>,'users');" />
</td>
<td class="pla">
<input class="text" type="text" id="users_by_name_<?php echo $i; ?>" value="<?php echo $database->getUserField($users[$i], 'username', 0); ?>" name="users_by_name[<?php echo $i; ?>]" maxlength="50" onkeyup="checkInputs(<?php echo $i; ?>,'users');" />
</td>
<td class="ad"></td>
</tr>
<?php } ?>
<tr>
<td class="id">
<input class="text" type="text" id="users_by_id_<?php echo $i; ?>" maxlength="15" name="users_by_id[<?php echo $i; ?>]" onkeyup="checkInputs(<?php echo $i; ?>,'users');" />
</td>
<td class="pla">
<input class="text" type="text" id="users_by_name_<?php echo $i; ?>" maxlength="50" name="users_by_name[<?php echo $i; ?>]" onkeyup="checkInputs(<?php echo $i; ?>,'users');" />
</td>
<td class="ad">
<img class="add" src="img/x.gif" title="add" alt="add" onclick="addRow('user_list')" />
</td>
</tr>
</tbody></table>
<script type="text/javascript">
showCheckList();
</script>
<?php } ?>
<p class="btn"><input type="image" value="ok" name="s1" id="fbtn_ok" class="dynamic_img" src="img/x.gif" alt="OK" /></p></form>
File diff suppressed because one or more lines are too long
+19
View File
@@ -0,0 +1,19 @@
<?php
#################################################################################
## -= YOU MAY NOT REMOVE OR CHANGE THIS NOTICE =- ##
## --------------------------------------------------------------------------- ##
## Filename 404.tpl ##
## Developed by: aggenkeech ##
## License: TravianX Project ##
## Copyright: TravianX (c) 2010-2012. All rights reserved. ##
## ##
#################################################################################
?>
<div style="margin-top: 50px;">
<div style="text-align: center">
<h1>404 - File not found</h1>
<img src="../../gpack/travian_default/img/misc/404.gif" title="Not Found" alt="Not Found"><br />
<p>We looked 404 times already but can't find anything, Not even an X marking the spot.</p>
<p>This system is not complete yet. So the page probably does not exist.</p><br>
</div>
</div>