mirror of
https://github.com/Shadowss/TravianZ.git
synced 2026-08-11 22:01:00 +00:00
Edit some access for MH user and recreate mass messaage
Edit some access for MH user and recreate mass message and new maintenance system view for admins
This commit is contained in:
@@ -53,7 +53,7 @@ $user = $database->getUserArray($id,1);
|
||||
<div>to <a href="admin.php?p=player&uid=<?php echo $user['id']; ?>"><?php echo $user['username']; ?></a></div>
|
||||
</div>
|
||||
|
||||
<form method="post" action="../Admin/Mods/sendMessage.php" name="msg">
|
||||
<form method="post" action="../GameEngine/Admin/Mods/sendMessage.php" name="msg">
|
||||
<div class="msg-body">
|
||||
<input type="hidden" name="uid" value="<?php echo $id; ?>">
|
||||
|
||||
|
||||
@@ -18,7 +18,9 @@
|
||||
## --------------------------------------------------------------------------- ##
|
||||
#################################################################################
|
||||
$unarray = array(1=>U1,U2,U3,U4,U5,U6,U7,U8,U9,U10,U11,U12,U13,U14,U15,U16,U17,U18,U19,U20,U21,U22,U23,U24,U25,U26,U27,U28,U29,U30,U31,U32,U33,U34,U35,U36,U37,U38,U39,U40,U41,U42,U43,U44,U45,U46,U47,U48,U49,U50,U99,U0);
|
||||
if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN);
|
||||
if (empty($_SESSION['access']) || $_SESSION['access'] < 9) {
|
||||
die(defined('ACCESS_DENIED_ADMIN') ? ACCESS_DENIED_ADMIN : 'Access Denied: You are not Admin!');
|
||||
}
|
||||
$id = $_GET['did'];
|
||||
if(isset($id)){
|
||||
$abtech = $database->getABTech($id);
|
||||
|
||||
@@ -18,7 +18,9 @@
|
||||
## --------------------------------------------------------------------------- ##
|
||||
#################################################################################
|
||||
$unarray = [1=>U1,U2,U3,U4,U5,U6,U7,U8,U9,U10,U11,U12,U13,U14,U15,U16,U17,U18,U19,U20,U21,U22,U23,U24,U25,U26,U27,U28,U29,U30,U31,U32,U33,U34,U35,U36,U37,U38,U39,U40,U41,U42,U43,U44,U45,U46,U47,U48,U49,U50,U99,U0];
|
||||
if($_SESSION['access'] < 9) die(ACCESS_DENIED_ADMIN);
|
||||
if (empty($_SESSION['access']) || $_SESSION['access'] < 9) {
|
||||
die(defined('ACCESS_DENIED_ADMIN') ? ACCESS_DENIED_ADMIN : 'Access Denied: You are not Admin!');
|
||||
}
|
||||
$id = $_GET['did'];
|
||||
if(isset($id)){
|
||||
$units = $database->getUnit($village['wref']);
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
## Copyright : TravianZ (c) 2010-2025. All rights reserved. ##
|
||||
## --------------------------------------------------------------------------- ##
|
||||
#################################################################################
|
||||
if($_SESSION['access'] < ADMIN) die("Access Denied!");
|
||||
if($_SESSION['access'] < MULTIHUNTER) die("Access Denied!");
|
||||
|
||||
$error = '';
|
||||
$success = '';
|
||||
|
||||
@@ -0,0 +1,112 @@
|
||||
<?php
|
||||
#################################################################################
|
||||
## -= YOU MAY NOT REMOVE OR CHANGE THIS NOTICE =- ##
|
||||
## --------------------------------------------------------------------------- ##
|
||||
## Filename : massmessage.tpl ##
|
||||
## Type : Admin Panel Frontend ##
|
||||
## --------------------------------------------------------------------------- ##
|
||||
## Developed by : Dzoki (Original) ##
|
||||
## Refactored by : Shadow ##
|
||||
## Redesign by : Shadow ##
|
||||
## --------------------------------------------------------------------------- ##
|
||||
## Project : TravianZ ##
|
||||
## GitHub : https://github.com/Shadowss/TravianZ ##
|
||||
#################################################################################
|
||||
if($_SESSION['access'] < ADMIN) die("Access Denied: You are not Admin!");
|
||||
$id = $_SESSION['id'];
|
||||
$_SESSION['mass_subject'] = $_SESSION['mass_subject'] ?? '';
|
||||
$_SESSION['mass_color'] = $_SESSION['mass_color'] ?? 'black';
|
||||
?>
|
||||
<style>
|
||||
.massmsg-wrap{max-width:700px;margin:30px auto;font-family:Verdana}
|
||||
.massmsg-head{display:flex;align-items:center;gap:8px;margin-bottom:16px}
|
||||
.massmsg-head svg{width:26px;height:26px}
|
||||
.massmsg-head h2{margin:0;font-size:18px}
|
||||
|
||||
.massmsg-card{background:#fff;border:1px solid #ddd;border-radius:10px;padding:20px;box-shadow:0 2px 6px rgba(0,0,0,.06)}
|
||||
.massmsg-card .top{display:flex;align-items:center;gap:12px;margin-bottom:16px}
|
||||
.massmsg-card .icon{background:linear-gradient(135deg,#e67e22,#d35400);width:44px;height:44px;border-radius:50%;display:flex;align-items:center;justify-content:center;flex-shrink:0}
|
||||
.massmsg-card .icon svg{width:24px;height:24px;fill:#fff}
|
||||
.massmsg-card h3{margin:0;font-size:15px}
|
||||
.massmsg-card p{margin:2px 0 0;color:#666;font-size:12px}
|
||||
|
||||
.massmsg-form{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:14px}
|
||||
.massmsg-form .field{display:flex;flex-direction:column;gap:4px}
|
||||
.massmsg-form label{font-size:11px;color:#555;font-weight:bold}
|
||||
.massmsg-form input,.massmsg-form textarea{padding:9px 10px;border:1px solid #ccc;border-radius:6px;font-size:13px;font-family:Verdana}
|
||||
.massmsg-form input:focus,.massmsg-form textarea:focus{outline:none;border-color:#e67e22;box-shadow:0 0 0 2px rgba(230,126,34,.2)}
|
||||
.massmsg-form .full{grid-column:1/-1}
|
||||
.massmsg-form button{grid-column:1/-1;background:#e67e22;color:#fff;border:0;padding:10px;border-radius:6px;font-weight:bold;cursor:pointer;font-size:14px;display:flex;align-items:center;justify-content:center;gap:6px}
|
||||
.massmsg-form button:hover{background:#d35400}
|
||||
|
||||
.massmsg-success{margin-top:16px;padding:10px;background:#fef5e7;border:1px solid #e67e22;color:#a04000;border-radius:6px;text-align:center;font-weight:bold}
|
||||
.massmsg-confirm{background:#fff3cd;border:1px solid #ffeaa7;padding:15px;border-radius:8px;margin-bottom:15px}
|
||||
</style>
|
||||
|
||||
<div class="massmsg-wrap">
|
||||
<div class="massmsg-head">
|
||||
<svg viewBox="0 0 24 24" fill="none"><path d="M20 4H4c-1.1 0-2.9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z" fill="#e67e22"/></svg>
|
||||
<h2>Mass Message</h2>
|
||||
</div>
|
||||
|
||||
<div class="massmsg-card">
|
||||
<div class="top">
|
||||
<div class="icon">
|
||||
<svg viewBox="0 0 24 24"><path d="M20 4H4c-1.1 0-2.9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z"/></svg>
|
||||
</div>
|
||||
<div>
|
||||
<h3>Send Message to All Players</h3>
|
||||
<p>Mesaj in-game pentru toti userii (ID > 5)</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php if(isset($_GET['confirm'])):?>
|
||||
<div class="massmsg-confirm">
|
||||
<b>Confirmare:</b> Esti sigur ca vrei sa trimiti?<br>
|
||||
<b>Subject:</b> <span style="color:<?=$_SESSION['mass_color']?>"><?=htmlspecialchars($_SESSION['mass_subject'])?></span>
|
||||
</div>
|
||||
<form action="../GameEngine/Admin/Mods/massmessage.php" method="POST" class="massmsg-form">
|
||||
<input type="hidden" name="admid" value="<?=$id?>">
|
||||
<input type="hidden" name="action" value="execute">
|
||||
<button type="submit" name="confirm" value="Yes" style="background:#27ae60">✓ Yes, Trimite</button>
|
||||
<button type="submit" name="confirm" value="No" style="background:#95a5a6;margin-top:8px">Anuleaza</button>
|
||||
</form>
|
||||
|
||||
<?php elseif(isset($_GET['sending'])):?>
|
||||
<div style="text-align:center;padding:30px">
|
||||
<div style="font-size:16px;margin-bottom:10px">Se trimit mesajele...</div>
|
||||
<div style="color:#666"><?=$_GET['msg']?? ''?></div>
|
||||
</div>
|
||||
|
||||
<?php else:?>
|
||||
<form action="../GameEngine/Admin/Mods/massmessage.php" method="POST" class="massmsg-form">
|
||||
<input type="hidden" name="admid" value="<?=$id?>">
|
||||
<input type="hidden" name="action" value="prepare">
|
||||
|
||||
<div class="field">
|
||||
<label>Subject</label>
|
||||
<input type="text" name="subject" placeholder="ex: Mentenanta" required maxlength="100">
|
||||
</div>
|
||||
|
||||
<div class="field">
|
||||
<label>Message Color</label>
|
||||
<input type="text" name="color" value="black" placeholder="black sau #e67e22">
|
||||
</div>
|
||||
|
||||
<div class="field full">
|
||||
<label>Message Content</label>
|
||||
<textarea name="message" rows="12" placeholder="Scrie mesajul... poti folosi [url] [img]" required></textarea>
|
||||
</div>
|
||||
|
||||
<button type="submit">
|
||||
<svg width="16" height="16" viewBox="0 0 24 24" fill="none"><path d="M2 21l21-9L2 3v7l15 2-15 2v7z" fill="#fff"/></svg>
|
||||
Continua
|
||||
</button>
|
||||
</form>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
|
||||
<?php if(isset($_GET['done'])){?>
|
||||
<div class="massmsg-success">✓ Mass message trimis cu succes la toti jucatorii!</div>
|
||||
<?php }?>
|
||||
</div>
|
||||
@@ -28,15 +28,20 @@
|
||||
</style>
|
||||
|
||||
<table id="member">
|
||||
<thead>
|
||||
<tr>
|
||||
<th colspan="2">Additional Information
|
||||
<thead>
|
||||
<tr>
|
||||
<th colspan="2">
|
||||
Additional Information
|
||||
|
||||
<?php if($_SESSION['access'] == ADMIN) { ?>
|
||||
<a href='admin.php?p=editAdditional&uid=<?php echo $id; ?>' class="edit-icon" title="Edit Player Additional Info">
|
||||
<svg viewBox="0 0 24 24"><path d="M12 20h9"/><path d="M16.5 3.5a2.1 2.1 0 0 1 3 3L7 19l-4 1 1-4 12.5-12.5z"/></svg>
|
||||
</a>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<?php } ?>
|
||||
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Access</td>
|
||||
|
||||
@@ -94,13 +94,13 @@
|
||||
<tr>
|
||||
<th>Population</th>
|
||||
<td><?php echo number_format($totalpop,0,',','.'); ?>
|
||||
<a href="?action=recountPopUsr&uid=<?php echo $user['id'];?>" title="Recount population" style="margin-left:6px;vertical-align:middle;display:inline-flex">
|
||||
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="#64748b" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path d="M21 12a9 9 0 1 1-3-6.7"/>
|
||||
<path d="M21 3v6h-6"/>
|
||||
</svg>
|
||||
</a>
|
||||
</td>
|
||||
<a href="?action=recountPopUsr&uid=<?php echo $user['id'];?>" title="Recount population" style="margin-left:6px;vertical-align:middle;display:inline-flex">
|
||||
<svg width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="#64748b" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
|
||||
<path d="M21 12a9 9 0 1 1-3-6.7"/>
|
||||
<path d="M21 3v6h-6"/>
|
||||
</svg>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th>Age</th>
|
||||
@@ -207,17 +207,17 @@
|
||||
?>
|
||||
|
||||
<tr><td colspan="2"><a href="?p=ban&uid=<?php echo $user['id'];?>">» Ban User</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=Newmessage&uid=<?php echo $user['id'];?>">» Send Message</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=editPlus&uid=<?php echo $user['id'];?>">» Edit Plus & Res Bonus</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=editSitter&uid=<?php echo $user['id'];?>">» Edit Sitters</a></td></tr>
|
||||
<!-- BUTON NOU ADAUGAT -->
|
||||
<tr><td colspan="2"><a href="?p=editProtection&uid=<?php echo $user['id'];?>">» Edit Protection</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=editPassword&uid=<?php echo $user['id'];?>">» Edit Password</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=editOverall&uid=<?php echo $user['id'];?>">» Edit Overall Off & Def</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=editWeek&uid=<?php echo $user['id'];?>">» Edit Weekly Off, Def, Raid</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=userlogin&uid=<?php echo $user['id'];?>">» User Login Log</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=userillegallog&uid=<?php echo $user['id'];?>">» User Illegal Log</a></td></tr>
|
||||
|
||||
<tr><td colspan="2"><a href="?p=Newmessage&uid=<?php echo $user['id'];?>">» Send Message</a></td></tr>
|
||||
<?php if($_SESSION['access'] == ADMIN) { ?>
|
||||
<tr><td colspan="2"><a href="?p=editPlus&uid=<?php echo $user['id'];?>">» Edit Plus & Res Bonus</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=editSitter&uid=<?php echo $user['id'];?>">» Edit Sitters</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=editProtection&uid=<?php echo $user['id'];?>">» Edit Protection</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=editPassword&uid=<?php echo $user['id'];?>">» Edit Password</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=editOverall&uid=<?php echo $user['id'];?>">» Edit Overall Off & Def</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=editWeek&uid=<?php echo $user['id'];?>">» Edit Weekly Off, Def, Raid</a></td></tr>
|
||||
<?php } ?>
|
||||
<tr><td colspan="2"><a href="?p=userlogin&uid=<?php echo $user['id'];?>">» User Login Log</a></td></tr>
|
||||
<tr><td colspan="2"><a href="?p=userillegallog&uid=<?php echo $user['id'];?>">» User Illegal Log</a></td></tr>
|
||||
<tr>
|
||||
<td colspan="2" class="desc2">
|
||||
<div class="desc2div">
|
||||
|
||||
@@ -0,0 +1,117 @@
|
||||
<?php
|
||||
if ($_SESSION['access'] < ADMIN) die("Access Denied");
|
||||
|
||||
$id = $_SESSION['id'];
|
||||
|
||||
$_SESSION['sys_subject'] = $_SESSION['sys_subject'] ?? '';
|
||||
$_SESSION['sys_message'] = $_SESSION['sys_message'] ?? '';
|
||||
$_SESSION['sys_color'] = $_SESSION['sys_color'] ?? 'black';
|
||||
?>
|
||||
|
||||
<style>
|
||||
.sysmsg-wrap{max-width:700px;margin:30px auto;font-family:Verdana}
|
||||
.sysmsg-head{display:flex;align-items:center;gap:8px;margin-bottom:16px}
|
||||
.sysmsg-head svg{width:26px;height:26px}
|
||||
.sysmsg-head h2{margin:0;font-size:18px}
|
||||
|
||||
.sysmsg-card{background:#fff;border:1px solid #ddd;border-radius:10px;padding:20px;box-shadow:0 2px 6px rgba(0,0,0,.06)}
|
||||
|
||||
.sysmsg-card .top{display:flex;align-items:center;gap:12px;margin-bottom:16px}
|
||||
.sysmsg-card .icon{background:linear-gradient(135deg,#8e44ad,#6c3483);width:44px;height:44px;border-radius:50%;display:flex;align-items:center;justify-content:center}
|
||||
.sysmsg-card .icon svg{width:24px;height:24px;fill:#fff}
|
||||
|
||||
.sysmsg-form{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:14px}
|
||||
.sysmsg-form .field{display:flex;flex-direction:column;gap:4px}
|
||||
.sysmsg-form label{font-size:11px;color:#555;font-weight:bold}
|
||||
.sysmsg-form input,.sysmsg-form textarea{
|
||||
padding:9px 10px;border:1px solid #ccc;border-radius:6px;font-size:13px;font-family:Verdana
|
||||
}
|
||||
.sysmsg-form input:focus,.sysmsg-form textarea:focus{
|
||||
outline:none;border-color:#8e44ad;box-shadow:0 0 0 2px rgba(142,68,173,.2)
|
||||
}
|
||||
.sysmsg-form .full{grid-column:1/-1}
|
||||
.sysmsg-form button{
|
||||
grid-column:1/-1;background:#8e44ad;color:#fff;border:0;padding:10px;
|
||||
border-radius:6px;font-weight:bold;cursor:pointer;font-size:14px;
|
||||
display:flex;align-items:center;justify-content:center;gap:6px
|
||||
}
|
||||
.sysmsg-form button:hover{background:#6c3483}
|
||||
|
||||
.sysmsg-confirm{
|
||||
background:#fff3cd;border:1px solid #ffeaa7;padding:15px;border-radius:8px;margin-bottom:15px
|
||||
}
|
||||
|
||||
.sysmsg-success{
|
||||
margin-top:16px;padding:10px;background:#e8f5e9;border:1px solid #2ecc71;
|
||||
color:#1e7e34;border-radius:6px;text-align:center;font-weight:bold
|
||||
}
|
||||
</style>
|
||||
|
||||
<div class="sysmsg-wrap">
|
||||
|
||||
<div class="sysmsg-head">
|
||||
<svg viewBox="0 0 24 24"><path d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z" fill="#8e44ad"/></svg>
|
||||
<h2>System Message</h2>
|
||||
</div>
|
||||
|
||||
<div class="sysmsg-card">
|
||||
|
||||
<?php if(isset($_GET['confirm'])): ?>
|
||||
|
||||
<div class="sysmsg-confirm">
|
||||
<b>Confirmare system message</b><br><br>
|
||||
<b>Color:</b> <span style="color:<?=htmlspecialchars($_SESSION['sys_color'])?>">
|
||||
<?=htmlspecialchars($_SESSION['sys_subject'])?>
|
||||
</span>
|
||||
<br><br>
|
||||
<div><?=nl2br(htmlspecialchars($_SESSION['sys_message']))?></div>
|
||||
</div>
|
||||
|
||||
<form action="../GameEngine/Admin/Mods/sysmessage.php" method="POST" class="sysmsg-form">
|
||||
<input type="hidden" name="admid" value="<?=$id?>">
|
||||
<input type="hidden" name="action" value="execute">
|
||||
|
||||
<button type="submit" name="confirm" value="Yes" style="background:#27ae60">✓ Send System Message</button>
|
||||
<button type="submit" name="confirm" value="No" style="background:#95a5a6;margin-top:8px">Cancel</button>
|
||||
</form>
|
||||
|
||||
<?php elseif(isset($_GET['sending'])): ?>
|
||||
|
||||
<div style="text-align:center;padding:30px">
|
||||
<div style="font-size:16px;margin-bottom:10px">Sending system message...</div>
|
||||
</div>
|
||||
|
||||
<?php else: ?>
|
||||
|
||||
<form action="../GameEngine/Admin/Mods/sysmessage.php" method="POST" class="sysmsg-form">
|
||||
|
||||
<input type="hidden" name="admid" value="<?=$id?>">
|
||||
<input type="hidden" name="action" value="prepare">
|
||||
|
||||
<div class="field">
|
||||
<label>Subject</label>
|
||||
<input type="text" name="subject" required maxlength="100">
|
||||
</div>
|
||||
|
||||
<div class="field">
|
||||
<label>Color</label>
|
||||
<input type="text" name="color" value="black">
|
||||
</div>
|
||||
|
||||
<div class="field full">
|
||||
<label>Message</label>
|
||||
<textarea name="message" rows="12" required></textarea>
|
||||
</div>
|
||||
|
||||
<button type="submit">Continue</button>
|
||||
|
||||
</form>
|
||||
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if(isset($_GET['done'])): ?>
|
||||
<div class="sysmsg-success">✓ System message sent successfully</div>
|
||||
<?php endif; ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -55,9 +55,11 @@ $img = $tribe==1 ? "" : $tribe-1;
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<?php if($_SESSION['access']==ADMIN){ ?>
|
||||
<div class="upg-foot">
|
||||
<?php if($tribe==5){ echo '<span style="color:#94a3b8">Upgrades Troops</span>'; } else { echo '<a href="admin.php?p=addABTroops&did='.$_GET['did'].'">Upgrades Troops</a>'; } ?>
|
||||
<a href="admin.php?p=techlog&did=<?=$_GET['did']?>" style="color:#64748b">Research Log</a>
|
||||
</div>
|
||||
<?php if(isset($_GET['ab'])) echo '<div style="text-align:right;padding:0 8px 6px;color:#dc2626;font-weight:600;font-size:12px">AB Tech updated</div>'; ?>
|
||||
<?php } ?>
|
||||
</div>
|
||||
@@ -122,7 +122,9 @@ if(isset($id)){
|
||||
<input type="hidden" name="did" value="<?php echo $_GET['did']; ?>">
|
||||
<input type="hidden" name="admid" value="<?php echo $_SESSION['id']; ?>">
|
||||
<input class="input-mini" type="text" name="newowner" value="<?php echo $user['id']; ?>" style="width:65px">
|
||||
<button class="btn-icon" title="Change"><?php echo $svgEdit; ?></button>
|
||||
<?php if($_SESSION['access'] == ADMIN) { ?>
|
||||
<button class="btn-icon" title="Change"><?php echo $svgEdit; ?></button>
|
||||
<?php } ?>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
@@ -131,7 +133,9 @@ if(isset($id)){
|
||||
<input type="hidden" name="did" value="<?php echo $_GET['did']; ?>">
|
||||
<input type="hidden" name="admid" value="<?php echo $_SESSION['id']; ?>">
|
||||
<input class="input-mini" type="text" name="villagename" value="<?php echo $village['name']; ?>" style="flex:1">
|
||||
<button class="btn-icon" title="Rename"><?php echo $svgEdit; ?></button>
|
||||
<?php if($_SESSION['access'] == ADMIN) { ?>
|
||||
<button class="btn-icon" title="Rename"><?php echo $svgEdit; ?></button>
|
||||
<?php } ?>
|
||||
</form>
|
||||
</td></tr>
|
||||
<tr><td class="label">Population</td><td colspan="2"><?php echo $village['pop'];?> <a href="admin.php?action=recountPop&did=<?php echo $_GET['did']; ?>" class="btn-icon" style="margin-left:4px"><?php echo $svgRefresh; ?></a></td></tr>
|
||||
@@ -142,7 +146,8 @@ if(isset($id)){
|
||||
</div>
|
||||
<!-- 2. RESOURCES - FULL WIDTH -->
|
||||
<div class="vcard">
|
||||
<div class="vhead">Resources <a href="admin.php?p=editResources&did=<?php echo $_GET['did']; ?>"><?php echo $svgEdit; ?></a></div>
|
||||
<div class="vhead">Resources<?php if($_SESSION['access'] == ADMIN) { ?><a href="admin.php?p=editResources&did=<?php echo $_GET['did']; ?>"><?php echo $svgEdit; ?></a><?php } ?>
|
||||
</div>
|
||||
<table class="vtable" style="text-align:center">
|
||||
<tr style="background:#f8fafc;font-size:11px;color:#64748b"><td style="text-align:left">Res</td><td>Amt</td><td>Cap</td><td>Prod</td></tr>
|
||||
<tr><td style="text-align:left"><img src="../img/admin/r/1.gif"> Wood</td><td><?php echo floor($village['wood']); ?></td><td rowspan="3"><?php echo $village['maxstore'];?></td><td><?php echo $production['wood'];?></td></tr>
|
||||
@@ -215,7 +220,7 @@ if(isset($id)){
|
||||
<div class="vhead">Buildings</div>
|
||||
<table class="vtable" style="text-align:center">
|
||||
<tr style="background:#f8fafc;font-size:11px;color:#64748b"><td>ID</td><td>GID</td><td style="text-align:left">Name</td><td>Lvl</td><td>Edit</td></tr>
|
||||
<?php for ($i = 1; $i <= 41; $i++){ if($i == 41) $i = 99; if($fdata['f'.$i.'t'] == 0) $bu = "-"; else $bu = $funct->procResType($fdata['f'.$i.'t']); echo '<tr><td>'.$i.'</td><td>'.$fdata['f'.$i.'t'].'</td><td style="text-align:left">'.$bu.'</td><td>'.$fdata['f'.$i].'</td><td><a href="admin.php?p=editVillage&did='.$_GET['did'].'" class="btn-icon">'.$svgEdit.'</a></td></tr>'; } ?>
|
||||
<?php for ($i = 1; $i <= 41; $i++){ if($i == 41) $i = 99; if($fdata['f'.$i.'t'] == 0) $bu = "-"; else $bu = $funct->procResType($fdata['f'.$i.'t']); echo '<tr><td>'.$i.'</td><td>'.$fdata['f'.$i.'t'].'</td><td style="text-align:left">'.$bu.'</td><td>'.$fdata['f'.$i].'</td><td>'.($_SESSION['access'] == ADMIN ? '<a href="admin.php?p=editVillage&did='.$_GET['did'].'" class="btn-icon">'.$svgEdit.'</a>': '').'</td></tr>'; } ?>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
|
||||
+11
-3
@@ -53,6 +53,14 @@ if (!empty($_GET['p'])) {
|
||||
case 'message':
|
||||
$subpage = 'Players Message';
|
||||
break;
|
||||
|
||||
case 'massmessage':
|
||||
$subpage = 'Mass Message';
|
||||
break;
|
||||
|
||||
case 'sysmessage':
|
||||
$subpage = 'System Message';
|
||||
break;
|
||||
|
||||
case 'map':
|
||||
$subpage = 'Map';
|
||||
@@ -578,8 +586,8 @@ Logged: <b><?=$adminName?></b> <span style="color:#999;font-size:11px">(<?=$rank
|
||||
<li class="sub"><a href="#">Messages</a>
|
||||
<ul>
|
||||
<li><a href="<?php echo rtrim(SERVER, '/'); ?>/nachrichten.php">Read In-Game Messages</a></li>
|
||||
<li><a href="<?php echo rtrim(SERVER, '/'); ?>/massmessage.php">Create Mass Message</a></li>
|
||||
<li><a href="<?php echo rtrim(SERVER, '/'); ?>/sysmsg.php">Create System Message</a></li>
|
||||
<li><a href="admin.php?p=massmessage">Create Mass Message</a></li>
|
||||
<li><a href="admin.php?p=sysmessage">Create System Message</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="sub"><a href="#">Ban</a>
|
||||
@@ -613,7 +621,7 @@ Logged: <b><?=$adminName?></b> <span style="color:#999;font-size:11px">(<?=$rank
|
||||
<ul>
|
||||
<li><a href="?p=admin_log"><font color="Red"><b>Admin Log</b></font></a></li>
|
||||
<li><a href="?p=config">Server Settings</a></li>
|
||||
<li><a href="?p=maintenance">Server Maintenance</a></li>
|
||||
<li><a href="?p=maintenance">Server Maintenance</a></li>
|
||||
<li><a href="?p=resetServer">Server Resetting</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
Reference in New Issue
Block a user