View Full Version : Dreamweaver Navigation barhelp

09-01-2010, 04:43 PM
To All
I am looking to replace a navigation that already exists on a huge website.

Existing Problem: When the customer wants to add something new to the collection, it takes forever to make the changes cause it is built in a table format.

Answer I would like is: How can I make it (without rebuilding the whole site) to where if I do one change, and upload it to the server, it changes the navigation sitewide?

Here is a link to it:

Keep in mind that the site is already live and I am looking for a simple solution to the left side navigation.

Thank you

09-01-2010, 05:08 PM
There isn't really an easy answer. Perhaps look at using; http://www.dreamweaverclub.com/php-includes.php when you next have to go through the site and change everything.

You'll also need to look at; http://www.desilva.biz/php/phpinhtml.html to make sure the PHP parses without having to change the file extension from .html

Hope that helps.

09-01-2010, 06:32 PM
Thank you for the quick response. Now I have run into another dilema. If you go to this link:


This has the php include working perfectly. Now I tried to put it into other pages that was another folder deeper in the site....

Link to the page:

As you can see an error comes up. Can someone please help meand show me what I am doing wrong.

Thank You

09-01-2010, 06:38 PM
Just change the path to the include in your page HTML. Make sure the path leads to the file. Like linking an image.

09-01-2010, 06:48 PM
Can you please use an example. This is my first time using php. I greatly appreciate it.


09-01-2010, 06:51 PM
<!--#include file="../includes/menu.php" -->

09-01-2010, 06:55 PM
It really hasn't got much to do with PHP. Paths are paths. Try ../../includes/menu.php That will probably do it.

09-01-2010, 09:21 PM
If a file is deeper down you'll also need to take this into account when linking to pages and not just the include its self.

For instance if a file is in the root folder of the site you would link to:
contact.php for example.

This will break the moment you have a file within another folder down.

You can get around this by using this code in your links

<a href="http://<?php echo $_SERVER['HTTP_HOST']; ?>/aboutUs.php">About Us</a>

This will get you back to the root.

09-02-2010, 06:13 AM
If a file is deeper down you'll also need to take this into account when linking to pages and not just the include its self.

Good shout, forgot about that. Knew there was a good reason to keep all my pages in one folder level.

09-02-2010, 05:27 PM
As far as links in include files, as long as they are relative to the site root, it doesn't matter where in the file structure the page with the include is located.