|
|
 |
February 29th, 2004, 05:32 AM
|
#1
|
|
New Member
Join Date: Feb 2004
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0
|
html menu problems
I am making a webpage and have run into a problem. The site has a menu list that I want to be on each webpage. The problem is each time I add a new item to the menu or change an item I would have to go through every other webpage and change the menu on those to. How can I make it so I can use that one page, and just update that page so it will apply to all other pages. Can it be done without frames?[:
|
|
|
February 29th, 2004, 05:53 AM
|
#2
|
|
Elite Veteran
SuperMember
Join Date: Jul 2003
Location: Southern UK
Age: 35
Posts: 3,126
Thanks: 28
Thanked 22 Times in 19 Posts
|
I think the answer here is to use server side includes ( SSI). This will be easy for you if you have ASP/ JSP/ PHP or other scripting languages available on the server.
Failing that, then I'm afraid you are gonna be stuck with either referencing a javascript (to write out the menu) or frames..... both of which are an extremely BAD idea.
SSI is the way to go.
|
|
|
February 29th, 2004, 06:14 AM
|
#3
|
Join Date: Jul 2003
Posts: 1,848
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 118
|
If your server doesn't support SSI, but you do have Dreamweaver, then you can also use Dreamweaver templates. This allows you to modify the template and then dreamweaver changes all the pages in your site for you.
|
|
|
February 29th, 2004, 09:04 AM
|
#4
|
|
Reputable Member
Join Date: Aug 2003
Location: Singapore
Posts: 318
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0
|
What you could do is to have the javascript made into a . js file which reduces the hassle of "copying and pasting" code. Then all you have to do for the menu is to just 'copy and paste' the code. Another method is to make the menu Flash, so all you need is some code to tell the browser to load your flash movie.
|
|
|
February 29th, 2004, 05:11 PM
|
#5
|
|
New Member
Join Date: Feb 2004
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0
|
Thanks for all the suggestions. I have tried SSI, but it doesn't work for me. I am designing this page on my home computer so i'm not sure if SSI or shtml would work for me. I guess the next thing I should try if javascript, but I have no idea where to begin. Does anyone know how to update multiple pages with javascript? It seems so easy in SSI, a shame it doesn't work.
|
|
|
February 29th, 2004, 05:45 PM
|
#6
|
|
New Member
Join Date: Feb 2004
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0
|
I got it working with javascript, but im not sure if this would be the best way to do it. What if someone doesnt have javascript working, then they wouldn't be able to navigate the site. Is there another way or is javascript the best way?
|
|
|
February 29th, 2004, 08:41 PM
|
#7
|
|
Elite Veteran
SuperMember
Join Date: Jul 2003
Location: Southern UK
Age: 35
Posts: 3,126
Thanks: 28
Thanked 22 Times in 19 Posts
|
javascript is a 'LAST' resort.... search engines can't spider your site with javascript navigation.
SSI is really the best option.... try and get it going.
|
|
|
February 29th, 2004, 08:51 PM
|
#8
|
|
New Member
Join Date: Feb 2004
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0
|
Can SSI work on a home computer? I followed a guide on how to use SSI, but it doesn't work for me. I'm not sure how to check if my computer supports it. I'm also not sure if my ocmputer supports shtml either.
|
|
|
March 1st, 2004, 12:05 PM
|
#9
|
|
Highly Reputable Member
Join Date: Feb 2004
Location: United Kingdom
Age: 22
Posts: 611
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0
|
so what is so bad about javascript menus?
|
|
|
March 1st, 2004, 12:27 PM
|
#10
|
|
Elite Veteran
SuperMember
Join Date: Jul 2003
Location: Southern UK
Age: 35
Posts: 3,126
Thanks: 28
Thanked 22 Times in 19 Posts
|
to answer that question (again), i'll just quote myself:-<blockquote id="quote"><font size="1" face="geneva, verdana, arial" id="quote">quote:<hr height="1" noshade id="quote">javascript is a 'LAST' resort.... search engines can't spider your site with javascript navigation.<hr height="1" noshade id="quote"></blockquote id="quote"></font id="quote">
|
|
|
March 1st, 2004, 04:39 PM
|
#11
|
Join Date: Jul 2003
Posts: 1,848
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 118
|
chobo - The answer to your question depends entirely on what server you're running. IIS or apache or another?
|
|
|
March 1st, 2004, 05:28 PM
|
#12
|
|
New Member
Join Date: Feb 2004
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0
|
I'm not running any server  I haven't uploaded my site to any hosting services yet. Right now it's just on my home computer with winxp pro running. I was looking around for another way to make my website "dynamic". It has to do with renaming my index. html -> index. php and making some include.headers and footer files. I'm not sure on exactly how to do this yet. But I think the concept behind it is to make one page a master template with which you can change, and control the layout for all you pages through that one page. As for the fonts, colors etc that is handled through CSS.
If anyone knows exactly how to use php to create a template could you please show me an example. Other sites I have found tend to leave out some stuff that newbs like myself can't pick up on.
|
|
|
March 1st, 2004, 06:35 PM
|
#13
|
Join Date: Jul 2003
Posts: 1,848
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 118
|
Ok, to use PHP or SSI (SHTML) you would have to install a server such as IIS or apache.
IIS is much easier on Windows XP Pro. You can install it by going to add/remove programs > add/remove windows components and selecting Internet Information services and pressing next, etc.
IIS automatically runs ASP which is similiar to PHP and can do basic include statements like SSI as well as far more complex coding. This site (webforumz) for example, runs on ASP.
Alternatively you can get some webspace that supports the language of your choice.
Once you've decided which avenue you want to go down, let us know and we'll help you further.
|
|
|
March 1st, 2004, 11:03 PM
|
#14
|
|
New Member
Join Date: Feb 2004
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0
|
I installed IIS like you said. I then tested that SSI example from a website, and it still doesn't work. Is there something else I need to do after I install IIS?
|
|
|
March 2nd, 2004, 03:47 AM
|
#15
|
Join Date: Jul 2003
Posts: 1,848
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 118
|
I don't know if SSI works by default on IIS - Guys? Help me here!
If not then you'll have to use ASP includes instead.
|
|
|
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|