Jump to content

php code works and dose not work - confused? take a look!


gaogier

Recommended Posts

Just because PHP was used to display the page does not make it a PHP issues. As such I am moving to HTML.

 

For the difference, you failed to state what part of the header was different. As such I will venture a guess you are referring to the Date.

 

 <td width="100%" height="25" class="normal_text04" >Today's Date: Wednesday 17th of February 2010 03:26 PM</td> 

That is the code that is on the systemnew site. Change it to:

 

 <td width="100%" height="25" class="normal_text04" align="right" >Today's Date: Wednesday 17th of February 2010 03:26 PM</td> 

 

And it will be like the runehints, as that is how it is in the runehints site.

 

EDIT:

The basic gist, the two pages are not exactly the same, there is a difference in the two or else they would display the same. Either a template is off or you did not copy some custom code that was written to one of the sites.

Link to comment
Share on other sites

the people I have spoken to say its a php error.

 

There are a few things html different, but if you look on the main site (using the same footer) http://runehints.com it works.

 

<?php
ob_start();
session_start();
?><?php



$time = microtime();
$time = explode(" ", $time);
$time = $time[1] + $time[0];
$start = $time;
?>
<?php include('aguestonline.inc'); ?>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>
    <title> .:RuneHints:. The Solution to all your RuneScape Problems</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <META name="copyright" CONTENT="Copyright RuneHints 2009">
    <META name="description" content="Runehints is a RuneScape tips site as the name suggests with dynamic sigs, hiscore based calculators and more">
    <META name="revisit-after" content="5 days">
    <META name="language" content="English">
    <META name="rating" content="general">
    <META name=distribution content=global>
    <META name="keywords" content="Rune scape,RuneScape,RuneHints,Rune hints, MMORPG, ORPG, MMO, MORPG, online games,games,multi-player games,guide,help,hints,forum,rpg,game player,map,guides,rune,reports ">
<meta name="alexaVerifyID" content="FHJFf__R58EVRHH7m1E2faOtyZA" />
    <link href="css/style.css" rel="stylesheet" type="text/css">
<? if (isset($use_jquery) && $use_jquery) { ?><script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/jquery.min.js"></script><? } ?>

    </head>
    
    <body>
    <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
      <tr>
        <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td height="2" align="left" valign="top"><img src="image/specer.png" width="1" height="1"></td>
              </tr>
              <tr>
                <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                  <tr>
                    <td height="29" align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                      <tr align="left" valign="top">
                        <td width="7"><img src="image/header_top-left.jpg" width="7" height="29"></td>
                        <td class="header-top-bg"><table width="100%"  border="0" align="right" cellpadding="0" cellspacing="0">
                          <tr align="left" valign="top">
                            <td> </td>
                            <td width="356" align="center"><a href="/" class="link_text01">Home</a>          <a href="/forums" class="link_text01">Forums</a>           <a href="/topsites" class="link_text01">Topsites</a>        <a href="http://runescape.com" class="link_text01">Play RuneScape</a></td>
                          </tr>
                        </table></td>
                        <td width="7"><img src="image/header_top-right.jpg" width="7" height="29"></td>
                      </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                      <tr align="left" valign="top">
                        <td width="1" bgcolor="#756649"><img src="image/specer.png" width="1" height="1"></td>
                        <td width="100%" class="header"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td height="120" align="left" valign="top" class="logo"> </td>
                          </tr>
                        </table></td>
                        <td width="1" align="right" bgcolor="#756649"><img src="image/specer.png" width="1" height="1"></td>
                      </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                      <tr align="left" valign="top">
                        <td width="12" height="25"><img src="image/header-bot-left.jpg" width="12" height="25"></td>
                        <td valign="middle" class="header-bot-bg"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td width="780" align="left" valign="middle" class="normal_text04">.:RuneHints:. The Solution to all your RuneScape Problems</td>
                            <td width="356" height="25" align="right" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                              <tr align="left" valign="middle">
                                <td width="100%" height="25" class="normal_text04" align="right" >Today's Date: <?php
    echo date('l jS \of F Y h:i A');
    ?></td>
                             
                              </tr>
                            </table></td>
                          </tr>
                        </table></td>
                        <td width="12" align="right"><img src="image/header-bot-right.jpg" width="12" height="25"></td>
                      </tr>
                    </table></td>
                  </tr>
                </table></td>
              </tr>
              <tr>
                <td height="5" align="left" valign="top"><img src="image/specer.png" width="1" height="1"></td>
              </tr>
            </table></td>
          </tr>
          <tr>
            <td align="left" valign="top"><table width="100%"  border="0" cellpadding="0" cellspacing="0">
              <tr align="left" valign="top">
                <td width="178"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                  <tr>
                    <td height="179" align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                      <tr>
                        <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                            <tr align="left" valign="top">
                              <td width="8" height="29"><img src="image/leftcol-box1-top-left.jpg" width="8" height="29"></td>
                              <td class="t-header-bg"><div>
                                  <table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                    <tr>
                                      <td height="29" align="left" valign="top" class="th"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                        <tr align="left" valign="top">
                                          <td width="30" height="29" align="center" valign="middle"><img src="image/arrow.jpg" width="17" height="9"></td>
                                          <td width="5"><img src="image/specer.png" width="1" height="1"></td>
                                          <td valign="middle" class="th_text">Main Menu </td>
                                        </tr>
                                      </table></td>
                                    </tr>
                                  </table>
                              </div></td>
                              <td width="8"><img src="image/leftcol-box1-top-right.jpg" width="8" height="29"></td>
                            </tr>
                        </table></td>
                      </tr>
                      <tr>
                        <td align="left" valign="top"><ul class="01">
                        <li  ><a href="/">Home    </a></li>
                       <li  ><a href="/forums">Forums  </a></li>
                       <li ><a href="/desktop">Desktop </a></li>
                       <li ><a href="http://rpg.runehints.com/rpg2">Dragon Knight RPG  </a></li>
                       <li ><a href="/contact">Contact Us  </a></li>
                       <li ><a href="http://www.runehints.com/forums/memberlist.php?mode=leaders">Staff Info </a></li>
                       <li ><a href="/topsites">Top Sites </a></li></ul>
                       </td>
                      </tr>
                      <tr>
                        <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                            <tr align="left" valign="top">
                              <td width="10"><img src="image/leftcol-box1-bot-left.jpg" width="10" height="16"></td>
                              <td class="leftcol-bot-mid-bg"> </td>
                              <td width="10"><img src="image/leftcol-box1-bot-right.jpg" width="10" height="16"></td>
                            </tr>
                        </table></td>
                      </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td height="5" align="left" valign="top"><img src="image/specer.png" width="1" height="1"></td>
                  </tr>
                  <tr>
                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                      <tr>
                        <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="8" height="29"><img src="image/leftcol-box1-top-left.jpg" width="8" height="29"></td>
                            <td valign="middle" class="t-header-bg"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                              <tr>
                                <td height="29" align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                  <tr align="left" valign="top">
                                    <td width="30" height="29" align="center" valign="middle"><img src="image/arrow.jpg" width="17" height="9"></td>
                                    <td width="5"><img src="image/specer.png" width="1" height="1"></td>
                                    <td valign="middle" class="th_text">RuneScape Hints </td>
                                  </tr>
                                </table></td>
                              </tr>
                            </table></td>
                            <td width="8"><img src="image/leftcol-box1-top-right.jpg" width="8" height="29"></td>
                          </tr>
                        </table></td>
                      </tr>
                      <tr>
                        <td align="left" valign="top"><ul class="02" ><li  ><a href="/quest.php">Quests  </a></li>
                                                               <li  ><a href="/skills.php">Skills </a></li>
                                                               <li ><a href="/sreport.php">Special Reports </a></li>
                                                               <li ><a href="/location.php">Location Guides </a></li>
                                                               <li ><a href="/map.php">Maps</a></li>
                                                               <li ><a href="/guild.php">Guild</a></li>
                                                               <li ><a href="/random.php">Random Events</a></li>
                                                               <li ><a href="/achi.php">Achievement Diary</a></li>
                                                               
                                                             
                                                              </ul>
                                </td>
                      </tr>
                      <tr>
                        <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="10"><img src="image/leftcol-box1-bot-left.jpg" width="10" height="16"></td>
                            <td class="leftcol-bot-mid-bg"> </td>
                            <td width="10"><img src="image/leftcol-box1-bot-right.jpg" width="10" height="16"></td>
                          </tr>
                        </table></td>
                      </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td height="5" align="left" valign="top"><img src="image/specer.png" width="1" height="1"></td>
                  </tr>
                  <tr>
                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                      <tr>
                        <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="8" height="29"><img src="image/leftcol-box1-top-left.jpg" width="8" height="29"></td>
                            <td valign="middle" class="t-header-bg"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                              <tr>
                                <td height="29" align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                  <tr align="left" valign="top">
                                    <td width="30" height="29" align="center" valign="middle"><img src="image/arrow.jpg" width="17" height="9"></td>
                                    <td width="5"><img src="image/specer.png" width="1" height="1"></td>
                                    <td valign="middle" class="th_text">RuneScape Data</td>
                                  </tr>
                                </table></td>
                              </tr>
                            </table></td>
                            <td width="8"><img src="image/leftcol-box1-top-right.jpg" width="8" height="29"></td>
                          </tr>
                        </table></td>
                      </tr>
                      <tr>
                        <td align="left" valign="top"><ul class="02" ><li  ><a href="/due.php">Item Database </a></li>
                                                               <li  ><a href="/due.php">NPC Database </a></li>
                                                               <li ><a href="/due.php">Monster Database </a></li>
                                                               <li ><a href="/due.php">Shop Database</a></li>
                                                             
                                                             
                                                              </ul>
                                </td>
                      </tr>
                      <tr>
                        <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="10"><img src="image/leftcol-box1-bot-left.jpg" width="10" height="16"></td>
                            <td class="leftcol-bot-mid-bg"> </td>
                            <td width="10"><img src="image/leftcol-box1-bot-right.jpg" width="10" height="16"></td>
                          </tr>
                        </table></td>
                      </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td height="5" align="left" valign="top"><img src="image/specer.png" width="1" height="1"></td>
                  </tr>
                  <tr>
                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                      <tr>
                        <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="8" height="29"><img src="image/leftcol-box1-top-left.jpg" width="8" height="29"></td>
                            <td valign="middle" class="t-header-bg"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                              <tr>
                                <td height="29" align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                  <tr align="left" valign="top">
                                    <td width="30" height="29" align="center" valign="middle"><img src="image/arrow.jpg" width="17" height="9"></td>
                                    <td width="5"><img src="image/specer.png" width="1" height="1"></td>
                                    <td valign="middle" class="th_text">RuneScape Tools</td>
                                  </tr>
                                </table></td>
                              </tr>
                            </table></td>
                            <td width="8"><img src="image/leftcol-box1-top-right.jpg" width="8" height="29"></td>
                          </tr>
                        </table></td>
                      </tr>
                      <tr>
                        <td align="left" valign="top"><ul class="02" ><li  ><a href="/due.php">Skill Calculators</a></li>
                                                               <li  ><a href="/due.php">Combat Calculator </a></li>
                                                               <li ><a href="/due.php">Max Hit Calculator </a></li>
                                                               <li ><a href="/due.php">Hiscores </a></li>
                                                               <li ><a href="/due.php">Skill Signatures </a></li>
                                                               <li ><a href="/due.php">Goal Signatures </a></li>
                                                               <li ><a href="/due.php">Race Signatures </a></li>

                                                               
                                                             
                                                              </ul>
                                </td>
                      </tr>
                      <tr>
                        <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="10"><img src="image/leftcol-box1-bot-left.jpg" width="10" height="16"></td>
                            <td class="leftcol-bot-mid-bg"> </td>
                            <td width="10"><img src="image/leftcol-box1-bot-right.jpg" width="10" height="16"></td>
                          </tr>
                        </table></td>
                      </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td height="5" align="left" valign="top"><img src="image/specer.png" width="1" height="1"></td>
                  </tr>
                  <tr>
                    <td height="100" align="center" valign="middle"><br><br><a href="http://runehints.com/topsites/in.php?id=1">
    <img src="http://runehints.com/topsites/button.php?id=1" border="0" alt="topsite">
    </a><br>
    
    <a href="http://www.runescape100.com/">
<img src="http://www.runescape100.com/rankings.php?u=251" alt="Runescape Help & Tips" border="0" /></a><a href="http://www.runescape100.com/namestats-251.htm">
<img src="http://www.runescape100.com/st.gif" alt="Rune Hints" border="0" /><br>
    
    <a href="http://www.wizzonline.co.uk/topsitelistings/">
    <img src="http://www.wizzonline.co.uk/topsitelistings/button.php?u=gaogier" alt="WizzOnline" border="0">
    </a><br>
    
    
    <a href="http://www.zdzira.com/topsite/">
    <img src="http://www.zdzira.com/topsite/button.php?u=1" alt="Z-100 Topsite - Runescape Topsite" border="0">
    </a><br>
    
    <a href="http://www.monsterraids.com">
    <img src="http://runehints.com/images/monsterraids.jpg" alt="Monster Raids" border="0">
    </a><br>
   
    <a href="http://runetower.com/topsite/">
    <img src="http://runetower.com/topsite/button.php?u=gaogier" alt="Runescape quests" border="0" />
    </a><br></td>
                  </tr>
                </table></td>
                <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                  <tr align="left" valign="top">

 

 

<?php

$use_jquery = true;

include ('header.inc');

?>

                <td width="5"><img src="image/specer.png" width="1" height="1"></td>

<td><table width="100%"  border="0" cellspacing="0" cellpadding="0">

                  <tr>

                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">

                      <tr align="left" valign="top">

                        <td width="8"><img src="image/th-midbody-left.jpg" width="8" height="29"></td>

                        <td class="t-header-bg"><table width="100%"  border="0" cellspacing="0" cellpadding="0">

                          <tr>

                            <td height="29" align="center" valign="middle" class="normal_text06">QUEST GUIDES</td>

                          </tr>

                        </table></td>

                        <td width="8"><img src="image/th-midbody-right.jpg" width="8" height="29"></td>

                      </tr>

                    </table></td>

                  </tr>

                  <tr>

                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">

                      <tr align="left" valign="top">

                        <td width="1" bgcolor="#756649"><img src="image/specer.png" width="1" height="1"></td>

                        <td width="1" bgcolor="#A18E6E"><img src="image/specer.png" width="1" height="1"></td>

                        <td width="1" bgcolor="#474B48"><img src="image/specer.png" width="1" height="1"></td>

                        <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">

                          <tr>

                            <td height="1" align="left" valign="top" bgcolor="#474B48"><img src="image/specer.png" width="1" height="1"></td>

                          </tr>

                          <tr>

                            <td align="left" valign="top" class="box_4">

                            <table width="100%"  border="0" cellspacing="0" cellpadding="0">

                            <tr>

                            <td>

<?php

 

function questview($id) {

 

require_once ('../mysql_connect.php');//connect to db

include ('includes/steps.php');

/* query for item */

    $query = "SELECT * FROM quest WHERE id=$id";

    $result = mysql_query ($query);

   

    /* if we get no results back, error out */

$numrtn = mysql_num_rows($result);

 

    if ($numrtn == 0) {

        echo "The quest guide requested cannot be found\n";

echo $id;

        return;

    }

    $row = mysql_fetch_assoc($result);

    /* easier to read variables and

    * striping out tags */

$id = $row['id'];

    $name = $row['name'];

    $contributors = $row['contributors'];

    $guideby = $row['guideby'];

    $added = $row['added'];

    $location = $row['startinglocation'];

    $members = $row['members'];

    $description = $row['description'];

    $difficulty = $row['difficulty'];

    $requirements = $row['requirements'];

    $items = $row['items'];

$reward = $row['reward'];

$guide = $row['mainbody'];

$length = $row['length'];

$updated = $row['updated'];

if ($members == "Y") {

$mem = "members only quest</b>, so it can only be done on a <b>members</b> server.";

}else{

$mem = "non-members quest</b>.";

}

if ($updated == 0){

$up = 'No-one has updated this quest guide';

}else{

$date2 = date("l jS F Y @ H:i:s ", $updated);

$up = 'It was last updated on '.$date2;

}

if ($contributors != ""){

$con = 'Thanks also to <b>'.$contributors.'</b> for changes.';

}else{

$con = 'No-one else has contributed to this quest guide.';

}

//$date = date("D M jS, Y g:i a", $added);

$date = date("l jS F Y @ H:i:s ", $added);

 

echo '

<div id="quest"><table width="100%" border="0">

  <tr>

    <td>

<h1 align="center">'.$name.'</h1>

';

echo step_js();

echo pick_clue($id);

echo toggle_reward();

echo toggle_clue();

echo '<br>';

echo '

<p class="text1">This quest guide was written by <b>'.$guideby.'</b> for use on Runehints and entered into the database on '.$date.'. '.$up.'. '.$con.'  <br /></p>

<p><span class="text1"><br />This quest is <b>'.$mem.'</span></p>

<p>

<span class="qtitle">Description: </span><span class="text1">'.$description.'</span></p>

<p><span class="qtitle">Difficulty Level: </span><span class="text1">'.$difficulty.'</span></p>

<p>

<span class="qtitle">Requirements: </span><span class="text1">'.$requirements.'</span></p>

 

<p>

<span class="qtitle">Items Needed During Quest: </span><span class="text1">'.$items.'</span></p>

<p>

<span class="qtitle">Starting Location: </span><span class="text1">'.$location.'</span></p>

  <p><span class="qtitles">Quest Instructions:</span></p>';

  echo list_steps($id, true);

echo '<p>

<div id="rewardwrap" style="display:none;"><span class="qtitle">Reward: </span><span class="text1">'.$reward.'</span></div></p>

   </td>

  </tr>

</table></div> ';

}

 

function selectquest(){

 

require_once ('../mysql_connect.php');//connect to db

global $sitestyle;

?>

      <?php

 

 

$result = mysql_query("SELECT * FROM quest");

 

$num_rows = mysql_num_rows($result);

?>

 

<table width="100%"  border="0" cellspacing="0" cellpadding="0">

  <tr>

    <td align="left" valign="top" class="normal_text02"><div align="justify">There are a total of <? echo $num_rows; ?> quest guides in our database. There are Free guides and Member guides. On RuneHints, all guides are free to use, but the Member guides require you to be on a RuneScape Member server to use them.</div></td>

  </tr>

  <tr>

    <td height="15" align="left" valign="top"> </td>

  </tr>

  <tr>

    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">

      <tr align="left" valign="top">

        <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">

          <tr>

            <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">

              <tr align="left" valign="top">

                <td width="16"><img src="image/011.jpg" width="16" height="26"></td>

                <td align="left" valign="top" class="quest_033"><table width="100%"  border="0" cellspacing="0" cellpadding="0">

                  <tr>

                    <td height="26" align="center" valign="middle" class="normal_text07">FREE QUEST GUIDES</td>

                  </tr>

                </table></td>

                <td width="16"><img src="image/022.jpg" width="16" height="26"></td>

              </tr>

            </table></td>

          </tr>

          <tr>

            <td align="left" valign="top" class="box_5"><table width="100%"  border="0" cellspacing="0" cellpadding="0">

            <?php

   

      /* query for quests */

        $n_query = "SELECT id, name, difficulty, members, sorter FROM quest WHERE members='n' ORDER BY sorter ASC";

   

        $n_result = mysql_query ($n_query);

    while ($n_row = mysql_fetch_assoc($n_result)) {

        $n_name = $n_row['name']; 

//$n_guideby = $n_row['guideby'];

$n_difficulty = $n_row['difficulty'];

$id = $n_row['id'];

        /* place table row data in

        * easier to use variables.

        * & display the data */

 

      echo '<tr align="left" valign="top"><td width="275" class="normal_text05"><a href="quest.php?flibble=questview&id='.$id.'&ic=1" style="color:#EED8B4;"><b>'.$n_name.'</b></a></td><td> </td><td width="73" class="normal_text05">'.$n_difficulty.'</td></tr>';

    }

        /* finish up table*/

?>

            </table></td>

          </tr>

          <tr>

            <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">

        &

Link to comment
Share on other sites

Somehow the send page wont paste fully here.

 

Here is the quest.php page

 

<?php
$use_jquery = true;
include ('header.inc');
?>
                <td width="5"><img src="image/specer.png" width="1" height="1"></td>
			<td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                  <tr>
                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                      <tr align="left" valign="top">
                        <td width="8"><img src="image/th-midbody-left.jpg" width="8" height="29"></td>
                        <td class="t-header-bg"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td height="29" align="center" valign="middle" class="normal_text06">QUEST GUIDES</td>
                          </tr>
                        </table></td>
                        <td width="8"><img src="image/th-midbody-right.jpg" width="8" height="29"></td>
                      </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                      <tr align="left" valign="top">
                        <td width="1" bgcolor="#756649"><img src="image/specer.png" width="1" height="1"></td>
                        <td width="1" bgcolor="#A18E6E"><img src="image/specer.png" width="1" height="1"></td>
                        <td width="1" bgcolor="#474B48"><img src="image/specer.png" width="1" height="1"></td>
                         <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td height="1" align="left" valign="top" bgcolor="#474B48"><img src="image/specer.png" width="1" height="1"></td>
                          </tr>
                          <tr>
                            <td align="left" valign="top" class="box_4">
                            	<table width="100%"  border="0" cellspacing="0" cellpadding="0">
                            		<tr>
                            			<td>
<?php

function questview($id) {

require_once ('../mysql_connect.php');//connect to db
include ('includes/steps.php');
/* query for item */
    $query = "SELECT * FROM quest WHERE id=$id";
    $result = mysql_query ($query);
    
    /* if we get no results back, error out */
$numrtn = mysql_num_rows($result);

    if ($numrtn == 0) {
        echo "The quest guide requested cannot be found\n";
	echo $id;
        return;
    }
    $row = mysql_fetch_assoc($result);
    /* easier to read variables and 
     * striping out tags */
$id = $row['id'];
    $name = $row['name'];
    $contributors = $row['contributors'];
    $guideby = $row['guideby'];
    $added = $row['added'];
    $location = $row['startinglocation'];
    $members = $row['members'];
    $description = $row['description'];
    $difficulty = $row['difficulty'];
    $requirements = $row['requirements'];
    $items = $row['items'];
$reward = $row['reward'];
$guide = $row['mainbody'];
$length = $row['length'];
$updated = $row['updated'];
if ($members == "Y") {
	$mem = "members only quest</b>, so it can only be done on a <b>members</b> server.";
}else{
	$mem = "non-members quest</b>.";
}
if ($updated == 0){
$up = 'No-one has updated this quest guide';	
}else{	
$date2 = date("l jS F Y @ H:i:s ", $updated);
$up = 'It was last updated on '.$date2;
}
if ($contributors != ""){
$con = 'Thanks also to <b>'.$contributors.'</b> for changes.';	
}else{
$con = 'No-one else has contributed to this quest guide.';
}
//$date = date("D M jS, Y g:i a", $added);
$date = date("l jS F Y @ H:i:s ", $added);

echo '
<div id="quest"><table width="100%" border="0">
  <tr>
    <td>
	<h1 align="center">'.$name.'</h1>
';
echo step_js();
echo pick_clue($id);
echo toggle_reward();
echo toggle_clue();
echo '<br>';
echo '
<p class="text1">This quest guide was written by <b>'.$guideby.'</b> for use on Runehints and entered into the database on '.$date.'. '.$up.'. '.$con.'  <br /></p>
<p><span class="text1"><br />This quest is <b>'.$mem.'</span></p>
<p>
<span class="qtitle">Description: </span><span class="text1">'.$description.'</span></p>
<p><span class="qtitle">Difficulty Level: </span><span class="text1">'.$difficulty.'</span></p>
<p>
<span class="qtitle">Requirements: </span><span class="text1">'.$requirements.'</span></p>

<p>
<span class="qtitle">Items Needed During Quest: </span><span class="text1">'.$items.'</span></p>
<p>
<span class="qtitle">Starting Location: </span><span class="text1">'.$location.'</span></p>
  <p><span class="qtitles">Quest Instructions:</span></p>';
  echo list_steps($id, true);
echo '<p>
<div id="rewardwrap" style="display:none;"><span class="qtitle">Reward: </span><span class="text1">'.$reward.'</span></div></p>
   </td>
  </tr>
</table></div> ';
}

function selectquest(){

require_once ('../mysql_connect.php');//connect to db
global $sitestyle;
?>
      <?php


$result = mysql_query("SELECT * FROM quest");

$num_rows = mysql_num_rows($result);
?>

<table width="100%"  border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td align="left" valign="top" class="normal_text02"><div align="justify">There are a total of <? echo $num_rows; ?> quest guides in our database. There are Free guides and Member guides. On RuneHints, all guides are free to use, but the Member guides require you to be on a RuneScape Member server to use them.</div></td>
  </tr>
  <tr>
    <td height="15" align="left" valign="top"> </td>
  </tr>
  <tr>
    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
      <tr align="left" valign="top">
        <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
              <tr align="left" valign="top">
                <td width="16"><img src="image/011.jpg" width="16" height="26"></td>
                <td align="left" valign="top" class="quest_033"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                  <tr>
                    <td height="26" align="center" valign="middle" class="normal_text07">FREE QUEST GUIDES</td>
                  </tr>
                </table></td>
                <td width="16"><img src="image/022.jpg" width="16" height="26"></td>
              </tr>
            </table></td>
          </tr>
          <tr>
            <td align="left" valign="top" class="box_5"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
            <?php
    
	      /* query for quests */
        $n_query = "SELECT id, name, difficulty, members, sorter FROM quest WHERE members='n' ORDER BY sorter ASC";
    
        $n_result = mysql_query ($n_query);
    while ($n_row = mysql_fetch_assoc($n_result)) {
        $n_name = $n_row['name'];  
	//$n_guideby = $n_row['guideby'];
	$n_difficulty = $n_row['difficulty'];
	$id = $n_row['id'];
        /* place table row data in 
         * easier to use variables.
         * & display the data */
		  
       echo '<tr align="left" valign="top"><td width="275" class="normal_text05"><a href="quest.php?flibble=questview&id='.$id.'&ic=1" style="color:#EED8B4;"><b>'.$n_name.'</b></a></td><td> </td><td width="73" class="normal_text05">'.$n_difficulty.'</td></tr>'; 
    }
        /* finish up table*/
	?>
            </table></td>
          </tr>
          <tr>
            <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
              <tr align="left" valign="top">
                <td width="49"><img src="image/0022.jpg" width="49" height="17"></td>
                <td height="17" bgcolor="#69582D"><img src="image/specer.png" width="1" height="1"></td>
                <td width="49"><img src="image/0033.jpg" width="49" height="17"></td>
              </tr>
            </table></td>
          </tr>
        </table></td>
        <td width="20"><img src="image/specer.png" width="1" height="1"></td>
        <td><table width="100%"  border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
              <tr align="left" valign="top">
                <td width="16"><img src="image/011.jpg" width="16" height="26"></td>
                <td class="quest_033"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                  <tr>
                    <td height="26" align="center" valign="middle" class="normal_text07">MEMBER QUEST GUIDES</td>
                  </tr>
                </table></td>
                <td width="16"><img src="image/022.jpg" width="16" height="26"></td>
              </tr>
            </table></td>
          </tr>
          <tr>
            <td align="left" valign="top" bgcolor="#675A45" class="box_5"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
		<?php

    /* query for quests */
        $y_query = "SELECT id, name, difficulty, members, sorter FROM quest WHERE members='y' ORDER BY sorter ASC";
    $y_result = mysql_query ($y_query);
    while ($y_row = mysql_fetch_assoc($y_result)) {
        $y_name = $y_row['name'];  
	//$y_guideby = $y_row['guideby'];
	$y_difficulty = $y_row['difficulty'];
	$yid = $y_row['id'];

        /* place table row data in 
         * easier to use variables.
         * & display the data */

        echo '<tr align="left" valign="top"><td width="275" class="normal_text05"><a href="quest.php?flibble=questview&id='.$yid.'&ic=1" style="color:#EED8B4;"><b>'.$y_name.'</b></a></td><td> </td><td width="73" class="normal_text05">'.$y_difficulty.'</td></tr>'; 
	}

        /* finish up table*/?>

	    </table></td>
          </tr>
          <tr>
            <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
              <tr align="left" valign="top">
                <td width="49"><img src="image/0022.jpg" width="49" height="17"></td>
                <td height="17" bgcolor="#69582D"><img src="image/specer.png" width="1" height="1"></td>
                <td width="49"><img src="image/0033.jpg" width="49" height="17"></td>
              </tr>
            </table></td>
          </tr>
        </table></td>
      </tr>
    </table></td>
  </tr>
</table>


                                   
<?php
}


switch($_GET['flibble']) {
    
case 'selectquest':
	selectquest();
	break;
case 'questview':
	questview($_GET['id']);
	break;		
    default:
        selectquest();
}

?>
					</td></tr></table>
					</td></tr></table>
                        </td>
                        <td width="1" bgcolor="#756649"><img src="image/specer.png" width="1" height="1"></td>
                        <td width="1" bgcolor="#A18E6E"><img src="image/specer.png" width="1" height="1"></td>
                        <td width="1" bgcolor="#474B48"><img src="image/specer.png" width="1" height="1"></td>
                      </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                      <tr align="left" valign="top">
                        <td width="63"><img src="image/0a.jpg" width="63" height="20"></td>
                        <td valign="bottom"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td height="17" align="left" valign="top" bgcolor="#746232"><img src="image/specer.png" width="1" height="1"></td>
                          </tr>
                          <tr>
                            <td height="1" align="left" valign="top" bgcolor="#474B48"><img src="image/specer.png" width="1" height="1"></td>
                          </tr>
                          <tr>
                            <td height="1" align="left" valign="top" bgcolor="#A18E6E"><img src="image/specer.png" width="1" height="1"></td>
                          </tr>
                          <tr>
                            <td height="1" align="left" valign="top" bgcolor="#756649"><img src="image/specer.png" width="1" height="1"></td>
                          </tr>
                        </table></td>
                        <td width="63"><img src="image/0b.jpg" width="63" height="20"></td>
                      </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td height="5" align="left" valign="top"><img src="image/specer.png" width="1" height="1"></td>
                  </tr>
                </table></td>
			<td width="5"><img src="image/specer.png" width="1" height="1"></td>
              </tr>
		  
            </table>
<?
//include('difffooter.inc');
include('footer.inc');

?>

Link to comment
Share on other sites

Footer page is here

 

              </td>
            <td width="178"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                  <tr>
                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                        <tr align="left" valign="top">
                          <td width="8" height="29"><img src="image/rightcol-th-01.jpg" width="8" height="30"></td>
                          <td valign="top" class="right-col-th-bg"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                            <tr>
                              <td height="30" align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                <tr align="left" valign="top">
                                  <td width="30" height="29" align="center" valign="middle"><img src="image/arrow.jpg" width="17" height="9"></td>
                                  <td width="5"><img src="image/specer.png" width="1" height="1"></td>
                                  <td valign="middle" class="th_text">Recent Posts</td>
                                </tr>
                              </table></td>
                            </tr>
                          </table></td>
                          <td width="8"><img src="image/rightcol-th-02.jpg" width="8" height="30"></td>
                        </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td height="20" align="left" valign="top" class="rightcol-bg"><table width="100%"  border="0" cellspacing="8" cellpadding="0">
                      <tr>
                        <td align="left" valign="top" class="normal_text01"><p><center><marquee scrollamount="2" direction="up" height="200" scrolldelay="1" onMouseOver="this.stop()" onMouseOut="this.start()">             <?php
require_once ('../mysql_connect1.php');//connect to db
   
$forumQ=mysql_query("SELECT p.topic_id, p.forum_id, p.post_subject, u.user_id, u.username_clean, u.user_colour
FROM phpbb_posts AS p
INNER JOIN phpbb_users AS u
ON p.poster_id = u.user_id
WHERE p.post_approved=1
ORDER BY p.topic_id DESC
LIMIT 20");
while($forumRow = mysql_fetch_assoc($forumQ)){
echo " <a href=forums/viewtopic.php?f=".$forumRow['forum_id']."&t=".$forumRow['topic_id'].">".$forumRow['post_subject']."</a><br>   Author: <a href='./memberlist.php?mode=viewprofile&u=".$forumRow['user_id']."' style='color: ".$forumRow['user_colour'].";'>".$forumRow['username_clean']."</a><br><br>
";
}

?>
<br /><br />

<a href="/forums/">RuneHints<br />
The Solution to all your RuneScape Problems</a></marquee></center>
                      </tr>
                    </table></td>
                  </tr>
                  <tr>
                    <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                        <tr align="left" valign="top">
                          <td width="10"><img src="image/leftcol-box1-bot-left.jpg" width="10" height="16"></td>
                          <td class="leftcol-bot-mid-bg"> </td>
                          <td width="10"><img src="image/leftcol-box1-bot-right.jpg" width="10" height="16"></td>
                        </tr>
                    </table></td>
                  </tr>
                </table></td>
              </tr>
              <tr>
                <td height="5" align="left" valign="top"><img src="image/specer.png" width="1" height="1"></td>
              </tr>
              <tr>
                <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="8" height="29"><img src="image/rightcol-th-01.jpg" width="8" height="30"></td>
                            <td valign="top" class="right-col-th-bg"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                <tr>
                                  <td height="30" align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                      <tr align="left" valign="top">
                                        <td width="30" height="29" align="center" valign="middle"><img src="image/arrow.jpg" width="17" height="9"></td>
                                        <td width="5"><img src="image/specer.png" width="1" height="1"></td>
                                        <td valign="middle" class="th_text">Forum Stats</td>
                                      </tr>
                                  </table></td>
                                </tr>
                            </table></td>
                            <td width="8"><img src="image/rightcol-th-02.jpg" width="8" height="30"></td>
                          </tr>
                      </table></td>
                    </tr>
                    <tr>
                      <td height="20" align="left" valign="top" class="rightcol-bg"><table width="100%"  border="0" cellspacing="8" cellpadding="0">
                          <tr>
                            <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                              <tr>
                                <td height="20" align="left" valign="middle" class="normal_text01"><?php include_once('fostats.php') ?></td>
                              </tr>
                              <tr>
                                <td align="left" valign="top"> </td>
                              </tr>
                            </table></td>
                          </tr>
                      </table></td>
                    </tr>
                    <tr>
                      <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="10"><img src="image/leftcol-box1-bot-left.jpg" width="10" height="16"></td>
                            <td class="leftcol-bot-mid-bg"> </td>
                            <td width="10"><img src="image/leftcol-box1-bot-right.jpg" width="10" height="16"></td>
                          </tr>
                      </table></td>
                    </tr>
                </table></td>
              </tr>
              <tr>
                <td height="5" align="left" valign="top"><img src="image/specer.png" width="1" height="1"></td>
              </tr>
              <tr>
                <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="8" height="29"><img src="image/rightcol-th-01.jpg" width="8" height="30"></td>
                            <td valign="top" class="right-col-th-bg"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                <tr>
                                  <td height="30" align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                      <tr align="left" valign="top">
                                        <td width="30" height="29" align="center" valign="middle"><img src="image/arrow.jpg" width="17" height="9"></td>
                                        <td width="5"><img src="image/specer.png" width="1" height="1"></td>
                                        <td valign="middle" class="th_text">Site Stats</td>
                                      </tr>
                                  </table></td>
                                </tr>
                            </table></td>
                            <td width="8"><img src="image/rightcol-th-02.jpg" width="8" height="30"></td>
                          </tr>
                      </table></td>
                    </tr>
                    <tr>
                      <td height="20" align="left" valign="top" class="rightcol-bg"><table width="100%"  border="0" cellspacing="8" cellpadding="0">
                          <tr>
                            <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                              <tr>
                                <td height="20" align="left" valign="middle" class="normal_text01"><?php include_once('aguestonline.php') ?><br><?php include('totals.inc'); ?></td>
                              </tr>
                              <tr>
                                <td align="left" valign="top"> </td>
                              </tr>
                            </table></td>
                          </tr>
                      </table></td>
                    </tr>
                    <tr>
                      <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="10"><img src="image/leftcol-box1-bot-left.jpg" width="10" height="16"></td>
                            <td class="leftcol-bot-mid-bg"> </td>
                            <td width="10"><img src="image/leftcol-box1-bot-right.jpg" width="10" height="16"></td>
                          </tr>
                      </table></td>
                    </tr>
                </table></td>
              </tr>
              <tr>
                <td height="5" align="left" valign="top"><img src="image/specer.png" width="1" height="1"></td>
              </tr>
              <tr>
                <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="8" height="29"><img src="image/rightcol-th-01.jpg" width="8" height="30"></td>
                            <td valign="top" class="right-col-th-bg"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                <tr>
                                  <td height="30" align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                      <tr align="left" valign="top">
                                        <td width="30" height="29" align="center" valign="middle"><img src="image/arrow.jpg" width="17" height="9"></td>
                                        <td width="5"><img src="image/specer.png" width="1" height="1"></td>
                                        <td valign="middle" class="th_text">Poll</td>
                                      </tr>
                                  </table></td>
                                </tr>
                            </table></td>
                            <td width="8"><img src="image/rightcol-th-02.jpg" width="8" height="30"></td>
                          </tr>
                      </table></td>
                    </tr>
                    <tr>
                      <td height="20" align="left" valign="top" class="rightcol-bg"><table width="100%"  border="0" cellspacing="8" cellpadding="0">
                          <tr>
                            <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                                <tr>
                                  <td height="20" align="left" valign="middle" class="normal_text01"><?php
require_once ('mysql_connect.php');//connect to db
$current_query = "SELECT * FROM poll_current";
if ($current_result = mysql_query($current_query)) {
  $current_row = mysql_fetch_array($current_result);
  $current = $current_row['poll_num'];
}

if(isset($_POST['submit']) && ctype_digit($_POST['vote'])) {
  $query = 'UPDATE poll_answers SET votes=votes+1 WHERE choice=' . $_POST['vote'] .' && poll_num='.$current;
  $result = mysql_query($query);
  ob_end_clean();
  setcookie ('vote', 'voted', time()+1209600, '/', 'runehints.com', '0');
  ob_end_clean();
  header("Location: http://runehints.com/");
  require_once ('../mysql_connect.php');//connect to db
}

if (isset($_COOKIE['vote']))  
{   
$question_query = 'SELECT * FROM poll_questions WHERE poll_num='.$current;
if($question_result = mysql_query($question_query)) {
	$question_row = mysql_fetch_array($question_result);
	$question = $question_row['question'];

$num_votes_query = 'SELECT SUM(votes) AS sumvotes
FROM poll_answers WHERE poll_num='.$current;

if ($result = mysql_query($num_votes_query)) {
  $row = mysql_fetch_array($result);
  $sum = $row['sumvotes'];
}
$totals_query = 'SELECT activity, votes FROM poll_answers WHERE poll_num='.$current.' ORDER BY choice ASC';
if ($result = mysql_query($totals_query)) {
echo '<font class="small2">'.$question.'<br /><br />';
echo '<table width="100%" cellpadding="1" cellspacing="0" border="0" style="font-family: Verdana; font-size: 9px; color: #efefef">';

  while($row = mysql_fetch_array($result)) {
  	$percent = round($row['votes'] * 100 / $sum);
  	echo '<tr><td width="3"></td><td width="100%" colspan="3">'. $row['activity'];
	echo '</td><td width="3"></td></tr><tr><td width="3"></td><td width="100%"><table width="100%"><tr><td height="9" width="'. $percent .'" background="http://www.runehints.com/images/bar.png"></td><td></td></tr></table></td><td width="3"></td><td width="0" align="right">'. $row['votes'] .'</td><td width="3"></td></tr>';
  }
  echo '<table cellpadding="0" cellspacing="0" border="0"><tr><td height="3"></td></tr></table><font style="font-size: 9px"><center><i>Votes: '.$sum.'</i></center></font>'; 
  
}else{
echo '<font class="small2">Sorry no polls are currently active</font>';
}
}	

}else{
$question_query = 'SELECT * FROM poll_questions WHERE poll_num='.$current;
if($question_result = mysql_query($question_query)) {
	$question_row = mysql_fetch_array($question_result);
	$question = $question_row['question'];


	  
	$form_query = 'SELECT * FROM poll_answers WHERE poll_num='.$current;
	if($result = mysql_query($form_query)) {
		echo '<form action='.$_SERVER['PHP_SELF'].' method="post">';
		echo '<font class="small2">'.$question.'<br />';
	  	while($row = mysql_fetch_array($result)) {
	   
			echo '<input type="radio" name="vote" value=' . $row['choice'] . '>'. $row['activity'] . '<br />';
	 	 }
			echo '<center><input name="submit" type="submit" value="Vote!"></form></center>';

	}

}else{
	echo '<font class="small2">Sorry no polls are currently active </font>'; 
}

}
?></td>
                                </tr>
                            </table></td>
                          </tr>
                      </table></td>
                    </tr>
                    <tr>
                      <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
                          <tr align="left" valign="top">
                            <td width="10"><img src="image/leftcol-box1-bot-left.jpg" width="10" height="16"></td>
                            <td class="leftcol-bot-mid-bg"> </td>
                            <td width="10"><img src="image/leftcol-box1-bot-right.jpg" width="10" height="16"></td>
                          </tr>
                      </table></td>
                    </tr>
                </table></td>
              </tr>
              <tr>
                <td align="left" valign="top"> </td>
              </tr>
              <tr>
                <td align="left" valign="top"> </td>
              </tr>
            </table></td>
          </tr>
        </table></td>
      </tr>
      <tr>
        <td align="left" valign="top"><table width="100%"  border="0" cellspacing="0" cellpadding="0">
          <tr align="left" valign="top">
            <td width="10"><img src="image/footer_left-bg.jpg" width="10" height="90"></td>
            <td class="footer_bg"><table width="100%" border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td height="30" align="center" valign="bottom">     <a href="#" class="link_text02">Home</a> |      <a href="#" class="link_text02">Forums</a> |       <a href="#" class="link_text02">Desktop</a> |      <a href="#" class="link_text02">Dragon Knight RPG</a> |      <a href="#" class="link_text02">Contact Us</a> |      <a href="#" class="link_text02">Staff Info</a> |      <a href="#" class="link_text02">Top Sites</a></td>
              </tr>
              <tr>
                <td align="center" valign="top" class="normal_text01">Copyright © 2004-2009 RuneHints.com. All Rights Reserved.<br>This site is not official and is in no ways affiliated with RuneScape. <br>All images related to Runescape are the property of Jagex Ltd.<br>Runescapeô is a trademark of Jagex Software © 1999-2009 Andrew Gower and JagexÆ, Ltd.</td>
              </tr>
            </table></td>
            <td width="10"><img src="image/footer_right-bg.jpg" width="10" height="90"></td>
          </tr>
        </table></td>
      </tr>
    </table></td>
  </tr>
</table>
</body>
</html>

<?php ob_flush(); ?>

Link to comment
Share on other sites

You still fail to point out what exactly is different. First you said it was just the header, ok, I found part of the header that was different, now it is more items on the site (Which I did take notice to).

 

You cannot expect someone to just waltz right in and find everything that is different on your site and fix it for you. Point out the specific parts that are different, paste the relevant code to those sections. As far as this being a PHP issue, well what is different between the two sites? Why not just re-copy the database / .php code straight from the good site to the bad site, as that should correct it. As the only way they could be displaying different is due to differences in code / database data.

 

I still fail to see why you would not just do a new straight copy of the database and website from siteA to siteB, as that seems the most logical choice to do and it should fix the errors.

Link to comment
Share on other sites

I'm going to guess that the actual problem you are trying to solve is that the footer section is not present on the http://runehints.com/quest.php page?

 

The html in the 'view source' ends right after the -

<center> Most  ever online was 979, on 21 April, 2008 at 10:33.</center><br>

 

You would need to at least identify the code responsible for that and the problem code is likely right after that code.

Link to comment
Share on other sites

so, if its in the totals.inc file.

<?php

require_once ('../mysql_connect.php');//connect to db

$skills = mysql_query("SELECT * FROM skill", $dbh) or die(mysql_error());
$quests = mysql_query("SELECT * FROM quest", $dbh) or die(mysql_error());
$location = mysql_query("SELECT * FROM location", $dbh) or die(mysql_error());
$map = mysql_query("SELECT * FROM map", $dbh) or die(mysql_error());
$sp = mysql_query("SELECT * FROM sp", $dbh) or die(mysql_error());
$guild = mysql_query("SELECT * FROM guild", $dbh) or die(mysql_error());
$random = mysql_query("SELECT * FROM random", $dbh) or die(mysql_error());
$achi = mysql_query("SELECT * FROM achi", $dbh) or die(mysql_error());

$num_rows_skills = mysql_num_rows($skills);
$num_rows_quests = mysql_num_rows($quests);
$num_rows_location = mysql_num_rows($location);
$num_rows_map = mysql_num_rows($map);
$num_rows_sp = mysql_num_rows($sp);
$num_rows_guild = mysql_num_rows($guild);
$num_rows_random = mysql_num_rows($random);
$num_rows_achi = mysql_num_rows($achi);




echo "<center>We currently have ";
echo $num_rows_skills + $num_rows_quests + $num_rows_location + $num_rows_map + $num_rows_sp + $num_rows_guild+ $num_rows_random+ $num_rows_achi;
echo " guides.</center>";
?>

 

I don't see whats wrong?

Link to comment
Share on other sites

I'm going to guess that you are getting a fatal runtime error because of the use of require_once() and the different mysql_connect.php and mysql_connect1.php files.

 

For debugging purposes, add the following two lines of code on the line immediately after your first opening <?php tag in quest.php -

 

ini_set("display_errors", "1");
error_reporting(E_ALL);

Link to comment
Share on other sites

what code should I use?

 

I think you miss the point of developing a web site and debugging code when it does not work. You don't throwaway code that you spent several man-hours developing that works the way your want it to just because it stops working when you move it to a different location. You find and fix the problem with your existing code, unless you are in the habit of throwing away your time and money.

 

What did the error_reporting/display_errors code show?

 

Edit to your edit: Are you sure you are not modifying the code you are posting here? Such as removing URL's being used in the include/require statements?

Link to comment
Share on other sites

I do not think this will matter, but maybe it will:

 

<?php
//require_once ('../mysql_connect.php');//connect to db

$skills = mysql_query("SELECT * FROM skill") or die(mysql_error());
$quests = mysql_query("SELECT * FROM quest") or die(mysql_error());
$location = mysql_query("SELECT * FROM location") or die(mysql_error());
$map = mysql_query("SELECT * FROM map") or die(mysql_error());
$sp = mysql_query("SELECT * FROM sp") or die(mysql_error());
$guild = mysql_query("SELECT * FROM guild") or die(mysql_error());
$random = mysql_query("SELECT * FROM random") or die(mysql_error());
$achi = mysql_query("SELECT * FROM achi") or die(mysql_error());

$num_rows_skills = mysql_num_rows($skills);
$num_rows_quests = mysql_num_rows($quests);
$num_rows_location = mysql_num_rows($location);
$num_rows_map = mysql_num_rows($map);
$num_rows_sp = mysql_num_rows($sp);
$num_rows_guild = mysql_num_rows($guild);
$num_rows_random = mysql_num_rows($random);
$num_rows_achi = mysql_num_rows($achi);

echo "<center>We currently have ";
echo $num_rows_skills + $num_rows_quests + $num_rows_location + $num_rows_map + $num_rows_sp + $num_rows_guild+ $num_rows_random+ $num_rows_achi;
echo " guides.</center>";
?>

 

Try that for the totals.inc and see if it works alright for you.

 

 

Link to comment
Share on other sites

Here is a more efficient version of code, as it does not pull all rows simply the count. I do not know if it will fix the issue, but yea, it will be (or should be) quicker and less resource intense.

 

As a note, this code ran fine on my server...

 

<?php
//require_once ('../mysql_connect.php');//connect to db

$skills = mysql_query("SELECT count(*) FROM skill") or die(mysql_error());
$num_rows_skills = mysql_result($skills, 0, 0);

$quests = mysql_query("SELECT count(*) FROM quest") or die(mysql_error());
$num_rows_quests = mysql_result($quests, 0, 0);

$location = mysql_query("SELECT count(*) FROM location") or die(mysql_error());
$num_rows_location = mysql_result($location, 0, 0);

$map = mysql_query("SELECT count(*) FROM map") or die(mysql_error());
$num_rows_map = mysql_result($map, 0, 0);

$sp = mysql_query("SELECT count(*) FROM sp") or die(mysql_error());
$num_rows_sp = mysql_result($sp, 0, 0);

$guild = mysql_query("SELECT count(*) FROM guild") or die(mysql_error());
$num_rows_guild = mysql_result($guild, 0, 0);

$random = mysql_query("SELECT count(*) FROM random") or die(mysql_error());
$num_rows_random = mysql_result($random, 0, 0);

$achi = mysql_query("SELECT count(*) FROM achi") or die(mysql_error());
$num_rows_achi = mysql_result($achi, 0, 0);

echo "<center>We currently have ";
echo $num_rows_skills + $num_rows_quests + $num_rows_location + $num_rows_map + $num_rows_sp + $num_rows_guild+ $num_rows_random+ $num_rows_achi;
echo " guides.</center>";
?>

Link to comment
Share on other sites

It has finally changed.

 

[phpBB Debug] PHP Notice: in file /home/gaogier/public_html/totals.inc on line 4: mysql_query() [function.mysql-query]: Access denied for user 'gaogier'@'localhost' (using password: NO)

[phpBB Debug] PHP Notice: in file /home/gaogier/public_html/totals.inc on line 4: mysql_query() [function.mysql-query]: A link to the server could not be established

Access denied for user 'gaogier'@'localhost' (using password: NO)

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

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.   Restore formatting

  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.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.