</tr> <tr height="15"> <td> </td> </tr> <? $sql_postdata = "SELECT * FROM $table[galaxyforum_posts] WHERE `thread_id` = '$thread_id' AND `galaxy_id` = '$playerdata[galaxy_id]' ORDER BY `date`"; $res_postdata = mysql_query($sql_postdata); if (@mysql_num_rows($res_postdata) > 0) { while ($rec_postdata = mysql_fetch_array($res_postdata)) { ?> <tr> <td> <table width="800" style="border: 1px solid #3C5762"> <tr> <td align="right">Posted by <b><?php echo getRulernameById($rec_postdata['poster_id']); ?> of <?php echo getPlanetnameById($rec_postdata['poster_id']); ?> </b> at <b><?echo date('H:i:s d-m-Y', $rec_postdata['date']);?></b></td> </tr> <tr> <td width="650"><?echo nl2br(parseBBcode(stripslashes($rec_postdata['text']), 1, 1, 1, 1, 0));?></td> </tr> </table> </td> </tr> <tr height="5"> <td></td> </tr>
echo $rec_threads['id']; ?> "> <tr> <td><a href="main.php?mod=<?php echo $mod; ?> &act=forum&subact=viewthread&thread_id=<?echo $rec_threads['id'];?>"><u><?echo stripslashes($rec_threads['subject']);?></u></a></td> <td><a href="main.php?mod=main&act=mail&do=compose&to=<?php echo $rec_threads['starter']; ?> "><?echo getRulernameById($rec_threads['starter']);?> of <?echo getPlanetnameById($rec_threads['starter']);?></a></td> <td><a href="main.php?mod=main&act=mail&do=compose&to=<?php echo $rec_threads['poster_id']; ?> "><?echo getRulernameById($rec_threads['poster_id']);?> of <?echo getPlanetnameById($rec_threads['poster_id']);?></a></td> <td><?echo date('H:i:s d-m-Y', $rec_threads['date']);?></td> <td align="center"><input type="submit" name="delthread" value="del"></td> </tr> </form> <? } } else { ?> <tr> <td colspan="5" align="center">There are no threads in this alliance forum.</td> </tr> <? } ?> </table>
$source_id = $piratefleet[$j]->getPlayerId(); $sql_upd_roids_attacker = "UPDATE `$table[players]` SET `roid_steel` = `roid_steel` + $steel_roids_capped, `roid_crystal` = `roid_crystal` + $crystal_roids_capped, `roid_erbium` = `roid_erbium` + $erbium_roids_capped, `roid_unused` = `roid_unused` + $unused_roids_capped WHERE `id` = $source_id"; $new['roid_steel'] -= $steel_roids_capped; $new['roid_crystal'] -= $crystal_roids_capped; $new['roid_erbium'] -= $erbium_roids_capped; $new['roid_unused'] -= $unused_roids_capped; mysql_query($sql_upd_roids_attacker) or die(mysql_error()); $c = getXYZ($target_id); $playername = getRulernameById($target_id).' of '.getPlanetnameById($target_id); addNews($source_id, 'Battle', 'Asteroid pirate report', '<table border="0" width="450" style="border: 1px solid #3C5762"> <tr style="border: 1px solid #3C5762"> <td colspan="2" width="450" >Asteroid pirate report from: <b>'.getShipProperty($ship_id, 'name').'</b></td> <tr style="border: 1px solid #3C5762"> <td width="150"><b>Asteroid type</b></td> <td width="250"><b>Amount stolen from '.$c[0].':'.$c[1].':'.$c[2].' ('.$playername.')</b></td> </tr> <tr style="border: 1px solid #3C5762"> <td>Steel</td> <td>'.$steel_roids_capped.'</td> </tr> <tr style="border: 1px solid #3C5762"> <td>Crystal</td> <td>'.$crystal_roids_capped.'</td>
?> <option value="<?echo $rec_galdata['id'].'" '.$sel;?>><?php echo $rec_galdata['rulername']; ?> of <?php echo $rec_galdata['planetname']; ?> </option> <? } } ?> </select> <? } elseif($GALAXY_INFO['moe_id'] > 0) { echo getRulernameById($GALAXY_INFO['moe_id']).' of '.getPlanetnameById($GALAXY_INFO['moe_id']); } ?> </td> </tr> <tr> <td width="175" align="left" background="img/bg_balk.jpg" colspan="2"><b>Other settings</b></td> </tr> <tr> <td align="left">Galaxy name:</td> <td align="left"> <? if ($playerdata['id'] == $GALAXY_INFO['commander_id']) { ?> <input type="text" name="topic" value="<?echo stripslashes($GALAXY_INFO['topic']);?>" size="100"> <? } else { echo stripslashes($GALAXY_INFO['topic']); }
$res_mails = mysql_query($sql_mails); if (@mysql_num_rows($res_mails) < 1) { ?> <tr><td width="800" colspan="4" align="center">There are no mails.</td></tr> <? } else { while ($rec_mails = mysql_fetch_array($res_mails)) { $bo = null; $bc = null; if ($rec_mails['read'] == 0) { $bo = '<b>'; $bc = '</b>'; } $c = getXYZ($rec_mails['from_player']); ?> <form method="POST" action="main.php?mod=main&act=mail&do=delete&mail_id=<?echo $rec_mails['id'];?>"> <tr> <td><a href="main.php?mod=main&act=mail&do=read&mail_id=<?echo $rec_mails['id'];?>"><?echo $bo.getRulernameById($rec_mails['from_player']).' of '.getPlanetnameById($rec_mails['from_player']).'('.$c[0].':'.$c[1].':'.$c[2].')'.$bc;?></a></td> <td><a href="main.php?mod=main&act=mail&do=read&mail_id=<?echo $rec_mails['id'];?>"><?echo $bo.$rec_mails['subject'].$bc;?></a></td> <td><a href="main.php?mod=main&act=mail&do=read&mail_id=<?echo $rec_mails['id'];?>"><?echo $bo.date('H:i d-m-Y', $rec_mails['date']).$bc;?></a></td> <td align="center"><input type="submit" name="deletemail" value=" Delete "></td> </tr> </form> <? } } ?> </table> </td> </tr> </table> </td> <td width="4" background="img/border/R.gif"> </td>
<tr> <td valign="top"> <table border="0" width="800"> <? $sql_alliancenews = "SELECT `id`, `subject`, `message`, `player_id`, `timestamp` FROM $table[alliancenews] WHERE `alliance_id` = '$alliance_id' ORDER BY `timestamp` DESC"; $res_alliancenews = mysql_query($sql_alliancenews); if (@mysql_num_rows($res_alliancenews) > 0) { while ($rec_alliancenews = mysql_fetch_array($res_alliancenews)) { ?> <tr> <td width="475" background="img/bg_balk.jpg"><b><?php echo stripslashes($rec_alliancenews['subject']); ?> </b></td> <td width="100" background="img/bg_balk.jpg"><b><?php echo getRulernameById($rec_alliancenews['player_id']); ?> of <?php echo getPlanetnameById($rec_alliancenews['player_id']); ?> </b></td> <td width="125" background="img/bg_balk.jpg"><b><?php echo date("H:i d-m-Y", $rec_alliancenews['timestamp']); ?> </b></td> </tr> <tr> <td colspan="2" valign="top"><?echo nl2br(stripslashes($rec_alliancenews['message']));?></td> <td align="center" valign="top"> <? $sql_alliancedata = "SELECT `founder_id` FROM $table[alliance] WHERE `id` = '$alliance_id'";
echo $to_xyz[0]; ?> &y=<?php echo $to_xyz[1]; ?> "><?echo $to_xyz[0].':'.$to_xyz[1].':'.$to_xyz[2];?></a> (<a href="main.php?mod=main&act=mail&do=compose&x=<?php echo $to_xyz[0]; ?> &y=<?php echo $to_xyz[1]; ?> &z=<?php echo $to_xyz[2]; ?> "><?php echo getRulernameById($rec_out['target_id']); ?> of <?php echo getPlanetnameById($rec_out['target_id']); ?> </a>)</td> <td <?if ($tdclass) echo $tdclass;?>><?php echo $eta; ?> </td> </tr> <? } } else { ?> <tr>
<form method="POST" action="main.php?mod=office&act=fleet&do=fleetaction&fleet_id=<?php echo $res_getfleets['id']; ?> "> <tr> <td <?if ($tdclass) echo $tdclass;?>><?php echo $res_getfleets['id']; ?> </td> <td <?if ($tdclass) echo $tdclass;?>><?php echo $res_getfleets['action']; ?> </td> <td <?if ($tdclass) echo $tdclass;?>><? $xyz = getXYZ($res_getfleets['target_id']); $rulername = getRulernameById($res_getfleets['target_id']); $planetname = getPlanetnameById($res_getfleets['target_id']); if ($rulername && $xyz) { echo $xyz[0].':'.$xyz[1].':'.$xyz[2].' ('.$rulername.' of '.$planetname.')'; } else { echo ' '; } ?></td> <td <?if ($tdclass) echo $tdclass;?>><? if (($res_getfleets['action_start'] > 0) || (($res_getfleets['action_start'] - getCurrentTick()) > 0)) { echo ($res_getfleets['action_start'] - getCurrentTick()); } else { echo 0; } ?></td> <td <?if ($tdclass) echo $tdclass;?>><?php
$to_xyz = getXYZ($rec_inc['target_id']); $eta = $rec_inc['action_start'] - getCurrentTick(); if ($eta < 0) { $eta = 0; } if ($rec_inc['action'] == 'attack') { $tdclass = 'class="hostile"'; } if ($rec_inc['action'] == 'defend') { $tdclass = 'class="friendly"'; } ?> <a <?if ($tdclass) echo $tdclass;?>><?echo $from_xyz[0].':'.$from_xyz[1].':'.$from_xyz[2];?> - <b><?php echo getRulernameById($rec_inc['player_id']); ?> of <?php echo getPlanetnameById($rec_inc['player_id']); ?> </b> -> <?echo $to_xyz[0].':'.$to_xyz[1].':'.$to_xyz[2];?> - <b><?php echo getRulernameById($rec_inc['target_id']); ?> of <?php echo getPlanetnameById($rec_inc['target_id']); ?> </b></a><br/> <? } } else { echo 'No incomings for your alliance.'; } ?> </td> </tr> <?