HTML question

My question is in regard to menus on a webpage.

Specifically, what tags or code can I implement so that if I make a change to my menu on one page, it will immediately show up on every page. I know about iframes, but I don’t consider that an option.

I know it doesn’t have to be just menus, but that’s the most obvious use I can find for a tag like that.

I don’t know php or any other web programming language except for HTML.

Nothing you can do but copy and paste. You’d need some kind of active script ato do what you want. HTML itself just isn’t up to the task.

Copy and paste, use a good “find and replace” function in a good HTML editor or use an SSI or PHP include.

What kind of changes? If you are thinking about layout changes, you can simply change the CSS file. If you are changing the contents, you need to do it to every page with that menu.

If you’re on a Unix server, you can try server-side includes. An include is a file that holds HTML (for example) and wherever you want to display that file, you just add one line of code. Whenever you change the code, it changes on all pages where it’s included.

If you’re on a Windows server, you can just include a file as such:



<!-- #include file="filename.html" --> 


It may take you a bit to figure out how to design your include file and the linked-from files correctly based on directory structure, but this will make updating your site alot easier.

You can always do that with PHP, but that’s more complicated than plain HTML.

What are you using to design the page? Dreamweaver lets you use “library items” where you can edit the chunk of code, and then put that “item” into different pages. Then, when you edit that library item, it changes on all pages.

Do yourself a favor and learn at least basic PHP. :slight_smile:

Do you mean two browser windows, with one being opened by the other? In that case, it can be done in Javascript.

If you’re talking about two pages on two different computers, then it’s a very difficult problem, because HTTP doesn’t ‘push’ documents to web browsers - the server waits for requests. If you need an application with real interactivity, you typically would go with flash or applets or something like that.

I’m designing it in good ol’e Notepad.

I shoulda been more specific about what I meant by “changes”. What I’m wanting is to be able to add an item to my menu on one page, and have it immediately show up on every page.

The include thing seems to be the best way to go.

Oh if only I could afford Dreamweaver. :slight_smile: