Jump to content
MakeWebGames

Error with my header


josh-j-c
 Share

Recommended Posts

Hello i have been having Major issues with my header recently i have modded it up and have been dealt with issues affecting my site, its structure and its effectiveness, the problems with my header i have found but not been able to repair are,

 

  • Attacking. When i attack someone it bring me up to the area where i select a weapon to attack my enemies with my the alignment is all completely out of place
  • Federal Jail. Once a person is in federal jail all that they can see is "You are in fed for Days" "Reason " Completely losing the reason and the amount of days.

 

There also was before an issue with the alignment of the federal jail but i somehow managed to repair that issue.

The header i am using ATM is located bellow, if anyone could have a shot at fixing it, it would be greatly appreciated, thanks.

 

<?php

class headers {
function startheaders() {
global $ir, $set;
$back="#333333"; //Define the background colour of your site here.
echo <<<EOF
<html>
<head>
<title>{$set['game_name']}</title>
<style>
body {
background: $back;
font-family: Arial, Helvetica, sans-serif;
}
table {
font-family: Tahoma;
font-size: 12px;
}
.table {
background-color:#000000;
}
.table3 {
background-color:#000000;
}
.table td {
background-color:#DEDEDE;
height:22px;
}
.table3 td {
background-color:#CCCCCC;
}
td .alt {
background-color:#EEEEEE;
height:22px;
}
td .h {
background-image:url(tablehgrad.png);
background-repeat:repeat-x;
font-weight: bold;
background-color: #D6D6D6;
}
.table th {
background-image:url(tablehgrad.png);
background-repeat:repeat-x;
font-weight: bold;
background-color: #D6D6D6;
}
a:link {
text-decoration: none;
color: #333333;
}
a:hover {
text-decoration: underline;
color: #666666;
}
a:active {
text-decoration: none;
color: #666666;
}
a:visited {
text-decoration: none;
color: #333333;
}
doodlebee


#:1177461 	
</style>
</head><body>
<center><table width=900 border=0 cellpadding=0 cellspacing=0><tr><td>
<image src='topheaderimage.png'></td></tr>
<td background='middleheaderimage.png'>

<table width=100% border=0 cellpadding=0 cellspacing=0>
<tr valign="top"><td width=23><center></td><td width=183><center>
EOF;
}
function userdata($ir,$lv,$fm,$cm,$dosessh=1)
{
global $db,$c,$userid, $set;
$IP = ($_SERVER['HTTP_X_FORWARDED_FOR'])
   ?  $_SERVER['HTTP_X_FORWARDED_FOR']
   :  $_SERVER['REMOTE_ADDR'];
$db->query("UPDATE users SET laston=unix_timestamp(),lastip='$IP' WHERE userid=$userid");
if(!$ir['email'])
{
global $domain;
die ("<body>Your account may be broken. Please mail [email protected]{$domain} stating your username and player ID.");
}
if($dosessh && ($_SESSION['attacking'] || $ir['attacking']))
{
print "You lost all your EXP for running from the fight.";
$db->query("UPDATE users SET exp=0,attacking=0 WHERE userid=$userid");
$_SESSION['attacking']=0;
}
$enperc=(int) ($ir['energy']/$ir['maxenergy']*100);
$wiperc=(int) ($ir['will']/$ir['maxwill']*100);
$experc=(int) ( $ir['exp']/$ir['exp_needed']*100);
$brperc=(int) ($ir['brave']/$ir['maxbrave']*100);
$hpperc=(int) ($ir['hp']/$ir['maxhp']*100);
$enopp=100-$enperc;
$wiopp=100-$wiperc;
$exopp=100-$experc;
$bropp=100-$brperc;
$hpopp=100-$hpperc;
$d="";
$u=$ir['username'];
if($ir['donatordays']) { $u = "<font color=green>[i]{$ir['username']}</font>[/i]";$d="[img=donator.gif]"; }

$gn=""; 
global $staffpage;

$bgcolor = 'FFFFFF';

print <<<OUT

<center>
[b]Name:[/b] $gn{$u} [{$ir['userid']}] $d

[b]Money:[/b] {$fm}

[b]Level:[/b] {$ir['level']}

[b]Points:[/b] {$ir['crystals']}


[[url='logout.php']Emergency Logout[/url]]
<hr />
[b]Energy:[/b] {$enperc}%

<img src=greenbar.png width=$enperc height=10><img src=redbar.png width=$enopp height=10>

[b]Will:[/b] {$wiperc}%

<img src=greenbar.png width=$wiperc height=10><img src=redbar.png width=$wiopp height=10>

[b]Brave:[/b] {$ir['brave']}/{$ir['maxbrave']}

<img src=greenbar.png width=$brperc height=10><img src=redbar.png width=$bropp height=10>
<hr />

OUT;
if($ir['fedjail'])
{
$q=$db->query("SELECT * FROM fedjail WHERE fed_userid=$userid");
$r=$db->fetch_row($q);
die("</td><td width=25></td><td width=643><center><font color=red size=+1>You have been put in the {$set['game_name']} Federal Jail for {$r['fed_days']} day(s).

Reason: {$r['fed_reason']}</font>[/b]</body></html>");
}
if(file_exists('ipbans/'.$IP))
{
die("[b]<font color=red size=+1>Your IP has been banned from {$set['game_name']}, there is no way around this.</font>[/b]</body></html>");
}
}
function menuarea()
{
include "mainmenu.php";
global $ir,$c;
$bgcolor = 'FFFFFF';
print '</td><td width=25></td><td width=643><center>';
print "[url='donate.php']* Donate today and gain loads of extra's! *[/url]

";
if($ir['hospital'])
{
 print "You are currently in hospital for {$ir['hospital']} minutes.
";
}
if($ir['jail'])
{
 print "You are currently in jail for {$ir['jail']} minutes.
";
}
}
function smenuarea()
{
include "smenu.php";
global $ir,$c;
$bgcolor = 'FFFFFF';
print '</td><td width=25></td><td width=643><center>';
}
function endpage()
{
global $db;
print <<<OUT
</td><td width=27></td></tr>
</table>
</td></tr>
<tr><td><image src='bottomheaderimage.png'></td></tr></table>
OUT;
}
}
?>
Link to comment
Share on other sites

Re: Error with my header

I was thinking could i just edit the location of all the images and move them around on the original header but then place the images i have instead of the originals if you catch my drift, would that be much quicker ?

 

Thanks for your advice though much appreciated

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...