OilSheikh Posted March 29, 2007 Share Posted March 29, 2007 Hi guys, this is my first post. Please try to help me as much as you can. I am creating an online shopping site. This is how it looks like - http://expresspc.110mb.com/home.php Now, if you scroll below, you see the footer. Now, do this > Click ABOUT US And you see the problems! 1. The Menu is no longer good-looking. 2. The logo pic's disappeared! 3. Scroll below and click ABOUT US. It says it cant find the page. It tries to look for it in BASE/BASE/about.php But, actual link is BASE/about.php and that worked from homepage! I have arranged the folder layouts like this. menu.php and base.php are in root. about.php is in folder BASE. menu.php is governed by menumaker.css base.php is governed by styler.css menumaker.css and styler.css are in root. Here's the codes HOME.PHP <html> <head> <title>Welcome to the Cyber Home of Express PC Sales</title> </head> <body> <?php include("menu.php"); ?> <table border="0" width="100%" id="table1" > <tr> <td colspan="2" align="left"><img src="HOME/index.1.jpg" width="620" height="280" border="0"></td> </tr> <tr> <td colspan="2" align="left"><font face="Arial" size="4"><b>Graphics like never before! Now Available from only </b> </font><b><font face="Arial"><i> <font color="#FF0000" size="6">£ 190</font></i></font><font face="Arial" size="4"> !</font></b></td> </tr> <tr> <td colspan="2" align="left"> </td> </tr> <tr> <td colspan="2" align="left"><img src="HOME/index.2.jpg" width="663" height="184" border="0"></td> </tr> <tr> <td colspan="2" align="left"><b><font face="Arial" size="4">Obliterate your enemies at Quad Core Speeds! </font></b> <b><font face="Arial" size="4">Now Available from only </font><font face="Arial"><i> <font color="#FF0000" size="6">£ 600</font></i></font><font face="Arial" size="4"> !</font></b></td> </tr> <tr> <td colspan="2" align="left"> </td> </tr> <tr> <td width="63%" align="left"> <img src="http://www.pc-infopratique.com/images/banque/x1950xtx.jpg"></td> <td width="36%" align="left"><b><font face="Arial" size="4">Stunning Lightning-Fast Graphics with GDDR4 Graphics RAM. A MUST for any Serious Gamer.</font></b><p> <b><font face="Arial" size="4">ATI X1950 Now Available from only </font></b></p> <p><b><font face="Arial"><i><font color="#FF0000" size="6">£ </font></i> </font><i><font face="Arial" size="6" color="#FF0000">150</font></i><font face="Arial" size="4"> !</font></b></td> </tr> <tr> <td width="63%" align="left"> </td> <td width="36%" align="left"> </td> </tr> <tr> <td align="left"><img border="0" src="HOME/vista2.jpg" width="101" height="134"><img border="0" src="HOME/vista3.jpg" width="103" height="132"><img border="0" src="HOME/wvista.jpg" width="102" height="135"></td> <td align="left"><b><font face="Arial" size="4">Jump to the new era of Microsoft Windows </font></b> <p><b><font face="Arial" size="4">Get Windows Vista from only</font><i><font face="Arial" size="6" color="#FF0000"> £ 50</font></i></b></td> </tr> </table> <?php include("base.php"); ?> </body> </html> ABOUT.PHP <html> <head> <title>About Us</title> <link rel="stylesheet" href="../../styler.css"> </head> <body> <?php include ("../menu.php"); ?> <span style="background-color: #FFFFFF"> <h1 align="left">About Us</h1> <h3 align="left"><span style="font-weight: 400"> Express PC Sales began it's journey in 2004. It was founded by a few Individuals with a Vision to revolutionize the way PC's are made available to the Public. These Individuals wanted to provide Low cost PC's to the public and at the same time ensure that customers received parts from Top Manufacturers and which were also Future-Proof for years to come. They wanted to free customers from the clutches of Multi-Million companies like DELL. </span></h3> <h3 align="left"><span style="font-weight: 400"> Since then, we have served over 150 Customers all over the country. Our PC's have been used in major areas of the Industry - from Cinemas to Web Hosting. We keep on improving our service from PC to PC and ensuring that Latest Technology is within everyone's reach. By directly purchasing from Suppliers who, in turn, directly import from the Hardware/Software Manufacturers, we are able to greatly reduce the Prices of our PC's. This approach avoids "middleman" companies. </span></h3> <h3 align="left"><span style="font-weight: 400"> We operate as an Online Business and trade mainly through Online channels such as ebay. Express PC Sales is Registered with the Inland Revenue as a business. We are also registered with Microsoft as a </span><span style="font-weight: 700"><i>Microsoft Partner</i></span><span style="font-weight: 400">. </span></h3> <h3 align="left"><img border="0" src="Z.jpg"></h3> <h3 align="left">Zahid Islam, <br>Director <br>( BSc Software Engineering )</h3> <?php include ("../base.php"); ?> </span> </body> </html> BASE.PHP <html> <head> <title>Base</title> <link rel="stylesheet" href ="styler.css" > </head> <body> <img border="0" src="BASE/line.gif" width="767" height="2"><br> <span class="class1"> <p align="center"><font face="Arial" size="2"><b> <a href="BASE/about.php"> About Us </a> <a href="BASE/map.php"> Site Map </a> <a href="BASE/terms.php"> Terms and Conditions </a> <a href="BASE/contact.php"> Contact Us </a></b></font></p> </span> </body> </html> please help me out folks. Would be appreciated. Quote Link to comment https://forums.phpfreaks.com/topic/44725-solved-footer-problems/ Share on other sites More sharing options...
Lytheum Posted March 29, 2007 Share Posted March 29, 2007 What does your menu.php file look like? I think it is trying to use a piece of information that it can't find, probably because it's calling it from another directory. For instance: Root - menu.php (stylercss.css) --BASE about.php (include menu.php) Instead of stylercss.css, it will be try to use /BASE/stylercss.css. See what I mean? Same thing with your logo on the about page. It is trying to view it from /root/BASE/logonew.JPG when it should just be /root/logonew.jpg Quote Link to comment https://forums.phpfreaks.com/topic/44725-solved-footer-problems/#findComment-217133 Share on other sites More sharing options...
OilSheikh Posted March 29, 2007 Author Share Posted March 29, 2007 Lytheum, here's the code for my menu.php <html> <head> <title>Menu</title> <link rel="stylesheet" href="menumaker.css"> <script type="text/javascript"><!--//--><![CDATA[//><!-- sfHover = function() { var sfEls = document.getElementById("nav").getElementsByTagName("LI"); for (var i=0; i<sfEls.length; i++) { sfEls[i].onmouseover=function() { this.className+=" sfhover"; } sfEls[i].onmouseout=function() { this.className=this.className.replace(new RegExp(" sfhover\\b"), ""); } } } if (window.attachEvent) window.attachEvent("onload", sfHover); //--><!]]></script> </head> <body> <h1><img border="0" src = "logonew.JPG" width="509" height="60"></h1> <ul id="nav"> <li><span style="background-color: #A4C1FF"><a href="home.php" title="HomePage">Home</a> <li><span style="background-color: #A4C1FF"><a href="#" title="Desktop Base Units">PC's</a> </span> <ul> <li><a href="PC/intel.php" title="PC's with an Intel Processor">Intel</a></li> <li><a href="PC/amd.php" title="PC's with an AMD Processor">AMD</a></li> </ul> </li> <li><span style="background-color: #A4C1FF"><a href="#">Hardware</a> </span> <ul> <li><a href="#">Processors</a> <ul> <li><a href="#">Intel</a> <ul> <li><a href="HW/pd.php">Pentium D</a></li> <li><a href="HW/c2d.php">Core 2 Duo</a></li> </ul> </li> <li><a href="HW/amd.php" title="AM2 and X2">AMD</a> </li> </ul> </li> <li><a href="#">Graphics Card</a> <ul> <li><a href = "#">ATI</a> <ul> <li><a href="HW/x1k.php" title="X1300 - X1850">X1000 Series</a></li> <li><a href="HW/x19.php" title="X1900 and X1950">X1900 Series</a></li> </ul> </li> <li><a href = "#">Nvidia</a> <ul> <li><a href="HW/7.php" title="Geforce 7100/7300/7600/7900/7950">7 Series</a></li> <li><a href="HW/8.php" title="8800">8 Series</a></li> </ul> </li> </ul> </li> <li><a href="#">Hard Drives</a> <ul> <li><a href = "#" title="ATA/IDE Hard Drives">ATA</a> <ul> <li><a href="HW/ataov200.php" title="200GB and above">200GB +</a></li> <li><a href="HW/atabel200.php" title="Below 200GB">200GB -</a></li> </ul> </li> <li><a href = "#">SATA</a> <ul> <li><a href="HW/sataov200.php" title="200GB and above">200GB +</a></li> <li><a href="HW/satabel200.php" title="Below 200GB">200GB -</a></li> </ul> </li> </ul> </li> <li><a href="#" title="DDR1 and DDR2">RAM</a> <ul> <li><a href="HW/512mb.php" title="PC3200/PC2-3200/PC2-4200/PC2-5200">512 MB</a></li> <li><a href="HW/1gb.php" title="PC3200/PC2-3200/PC2-4200/PC2-5200">1 GB</a></li> <li><a href="HW/2gb.php" title="PC3200/PC2-3200/PC2-4200/PC2-5200">2 GB</a></li> </ul> </li> <li><a href="HW/dvdrw.php" title="IDE DVD-Rewriter Drives">DVDRW Drives</a> </li> <li><a href="HW/per.php" title="Keyboard/Mouse/Speakers/Monitors/Printers">Peripherals</a> </li> </ul> </li> <li><span style="background-color: #A4C1FF"><a href="#">Software</a> </span> <ul> <li><a href="#" title="Microsoft Windows">MS Windows</a></li> <ul> <li><a href="SW/xp.php" title="Home/Media Center/Professional">XP</a></li> <li><a href="SW/vista.php" title="Home Basic/Home Premium">Vista</a></li> </ul> <li><a href="#" title="Microsoft Office">MS Office</a></li> <ul> <li><a href="SW/2003.php">2003</a></li> <li><a href="SW/2007.php">2007</a></li> </ul> <li><a href="SW/other.php" title="Nero/Microsoft Works/PowerDVD/Antivirus">Other Software</a></li> </ul> </li> <li><span style="background-color: #A4C1FF"><a href="#">Support</a> </span> <ul> <li><a href="forum.php" title="Discussions with EXPRESS Experts and Fellow Customers">Forum</a></li> <li><a href="dwnld.php" title="Download Recommended Software and Latest Drivers">Downloads</a></li> </ul> </li> <li><span style="background-color: #A4C1FF"><a href="acc.php" title="Log-in to your Account">My Account</a> </ul> </body> </html> The menu is based on the Suckerfish Menu style. Quote Link to comment https://forums.phpfreaks.com/topic/44725-solved-footer-problems/#findComment-217696 Share on other sites More sharing options...
Lytheum Posted March 29, 2007 Share Posted March 29, 2007 Ok, there's the problem. All of the link references in your menu.php are assuming that you will always call it from the root directory. In your case you're calling from the base directory as well. So you can either copy of all of the files you need into the BASE directory (css, menu, etc). Or you can give direct links for each link. Like so: If it says acc.php, turn it into http://expresspc.110mb.com/acc.php This should work whether you call it from the Root folder or BASE. Quote Link to comment https://forums.phpfreaks.com/topic/44725-solved-footer-problems/#findComment-217814 Share on other sites More sharing options...
OilSheikh Posted March 30, 2007 Author Share Posted March 30, 2007 Tnx dude. Will give both the methods a try later on and see. But, now I m off to sleeeep.... Will let u know how I get on. Quote Link to comment https://forums.phpfreaks.com/topic/44725-solved-footer-problems/#findComment-217834 Share on other sites More sharing options...
dsaba Posted March 30, 2007 Share Posted March 30, 2007 i believe it is because your style.css file is no longer accessed in yout about use page you switch directories from / (root) to /base copy your style.css there <link rel="stylesheet" href ="styler.css" > that means its looking for style.css in /base you could change it to this: <link rel="stylesheet" href ="http://website.com/styler.css" > that way it always looks for the style sheet in one directory Quote Link to comment https://forums.phpfreaks.com/topic/44725-solved-footer-problems/#findComment-217880 Share on other sites More sharing options...
Lytheum Posted March 30, 2007 Share Posted March 30, 2007 I've already directed him to do that, read above! Quote Link to comment https://forums.phpfreaks.com/topic/44725-solved-footer-problems/#findComment-217900 Share on other sites More sharing options...
OilSheikh Posted April 1, 2007 Author Share Posted April 1, 2007 Tnx a lot guys. Everything's OK now. Here's the latest working version http://expresspc.110mb.com/home.php Only problem I now see is that the menu is too quick for some of the PHP Pages in the Footer. But, this is random. Anyways, that's another story. Quote Link to comment https://forums.phpfreaks.com/topic/44725-solved-footer-problems/#findComment-218917 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.