Newbie - Includes aren't working online
From: JamesB (james_at_imajica.com)
Date: 03/14/04
- Next message: Sims: "Mozilla vs Netscape and getenv("HTTP_USER_AGENT")"
- Previous message: Andy Hassall: "Re: empty session-variable"
- Next in thread: Pedro Graca: "Re: Newbie - Includes aren't working online"
- Reply: Pedro Graca: "Re: Newbie - Includes aren't working online"
- Reply: JamesB: "Re: Newbie - Includes aren't working online"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 14 Mar 2004 12:39:26 +0000 (UTC)
Hi guys,
I've only just started using PHP4 this week and I seemed to be getting on
great until I hit this one problem.
I've built this dynamic menu system which displays e a variety of menus down
the side of the page. Which menu is displayed is controlled by a variable
which sits in the URL. The menu is inserted as an include into every page of
my site using the following code:
<?php include("../includes/menu.php"); ?>
This works fine and the menu is working 100% on my localhost version but the
moment I put it onto the clients test site it starts doing some very strange
things.
Firstly the menu isn't there. If you were to look at the code the include
has gone in fine but for some odd reason all of the PHP code has either not
executed or has been stripped out. I then run some tests on just the include
and again it's just showing the HTML code and nothing else.
I've tested the server with some basic lines of code and it's displaying a
'hello world' message fine, I've got an auto-forwarding on a page working
fine and I also run this code
<? if (file_exists(includes/menu.php)
{
print("It's here")
}
else
{
print("It's NOT here")
}
...which returns "It's here". So from what I can tell PHP is working fine
and the file is being inserted but it just won't run my code.
Oh one more thing, the system administrator is telling me that it could be
something to do with my paths and the way there setup but I've also tried an
absolute address on one of the pages and it still doesn't work.
Has anyone got any thoughts?
Thanks in advance.
JamesB
- Next message: Sims: "Mozilla vs Netscape and getenv("HTTP_USER_AGENT")"
- Previous message: Andy Hassall: "Re: empty session-variable"
- Next in thread: Pedro Graca: "Re: Newbie - Includes aren't working online"
- Reply: Pedro Graca: "Re: Newbie - Includes aren't working online"
- Reply: JamesB: "Re: Newbie - Includes aren't working online"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|