Go Back   CodingForums.com > :: Client side development > HTML & CSS

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 05-26-2009, 08:34 AM   PM User | #1
dejansoftware
New to the CF scene

 
Join Date: May 2009
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
dejansoftware is an unknown quantity at this point
Post Question regarding web site menu

Hi,

I have to upgrade old web site, the one big problem is menu on the right side.

It has at least 20 menu buttons - pages, and when they need to do simply update, they need to update each (20) pages.

I would like to put something, which will remove that each page has it's own menu, something like single file to update and that will reflect to all pages.

What is the best thing to do, can you give me some directions, links, or any help.

I can provide more info, just let me know.

Thanks
dejansoftware is offline   Reply With Quote
Old 05-26-2009, 08:42 AM   PM User | #2
abduraooft
Supreme Master coder!

 
abduraooft's Avatar
 
Join Date: Mar 2007
Location: N/A
Posts: 14,678
Thanks: 158
Thanked 2,182 Times in 2,169 Posts
abduraooft is just really niceabduraooft is just really niceabduraooft is just really niceabduraooft is just really niceabduraooft is just really nice
Quote:
What is the best thing to do, can you give me some directions, links, or any help.
Write the html code for your menu in a file, say menu.htm or menu.txt and then include this file wherever required using a server side script, say in PHP
PHP Code:
<div id="sidebar">
<?php
include "menut.txt";
?>
</div>
__________________
Quote:
The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)

Last edited by abduraooft; 05-26-2009 at 10:29 AM..
abduraooft is offline   Reply With Quote
Old 05-26-2009, 10:20 AM   PM User | #3
frankle
New Coder

 
Join Date: May 2009
Posts: 74
Thanks: 0
Thanked 7 Times in 7 Posts
frankle is an unknown quantity at this point
Quote:
Originally Posted by dejansoftware View Post
Hi,

I have to upgrade old web site, the one big problem is menu on the right side.

It has at least 20 menu buttons - pages, and when they need to do simply update, they need to update each (20) pages.

I would like to put something, which will remove that each page has it's own menu, something like single file to update and that will reflect to all pages.

What is the best thing to do, can you give me some directions, links, or any help.

I can provide more info, just let me know.

Thanks



You can write your menu code in one seperate file (and name it, e.g, menu.php) and include it in all the 20 pages simply with the following code:

<?php include("menu.php");?>

So, every time you make changes on the menu.php file it will reflect on each and every pages.


Regards.
frankle is offline   Reply With Quote
Reply

Bookmarks

Tags
buttons, html, menu, pages, update

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 09:50 AM.


Advertisement
Log in to turn off these ads.