Same Menu On Every Page

Same Menu On Every Page

am 10.08.2007 03:54:09 von Matt White

I am creating a page with 2

's - one is a menu and one holds the
page content. The menu is the same on every page. What is the best way
to get the HTML for the menu on every page without putting the full
source on every page? I'd rather have a separate menu.html file that
gets loaded into the menu
when each page loads. Thanks.

Re: Same Menu On Every Page

am 10.08.2007 04:00:01 von a.nony.mous

Matt White wrote:

> I am creating a page with 2

's - one is a menu and one holds the
> page content. The menu is the same on every page. What is the best
> way to get the HTML for the menu on every page without putting the
> full source on every page? I'd rather have a separate menu.html file
> that gets loaded into the menu
when each page loads. Thanks.

http://allmyfaqs.net/faq.pl?Include_one_file_in_another

--
-bts
-Motorcycles defy gravity; cars just suck

Re: Same Menu On Every Page

am 10.08.2007 05:07:43 von dorayme

In article
,
"Beauregard T. Shagnasty" wrote:

> Matt White wrote:
>
> > I am creating a page with 2

's - one is a menu and one holds the
> > page content. The menu is the same on every page. What is the best
> > way to get the HTML for the menu on every page without putting the
> > full source on every page? I'd rather have a separate menu.html file
> > that gets loaded into the menu
when each page loads. Thanks.
>
> http://allmyfaqs.net/faq.pl?Include_one_file_in_another

I sometimes wonder what other folks do in regard to the includes,
do they put in all the enclosing element markup within the
include or leave the container explicit in the html file to
remind the author how the include goes. I tend to go the greedy
route and put all in the include. This is to show high wire
courage in the face of a creeping dementia.

--
dorayme

Re: Same Menu On Every Page

am 10.08.2007 06:15:15 von a.nony.mous

dorayme wrote:

> "Beauregard T. Shagnasty" wrote:
>> Matt White wrote:
>>> I am creating a page with 2

's - one is a menu and one holds
>>> the page content. The menu is the same on every page. What is the
>>> best way to get the HTML for the menu on every page without putting
>>> the full source on every page? I'd rather have a separate menu.html
>>> file that gets loaded into the menu
when each page loads.
>>> Thanks.
>>
>> http://allmyfaqs.net/faq.pl?Include_one_file_in_another
>
> I sometimes wonder what other folks do in regard to the includes, do
> they put in all the enclosing element markup within the include or
> leave the container explicit in the html file to remind the author
> how the include goes. I tend to go the greedy route and put all in
> the include. This is to show high wire courage in the face of a
> creeping dementia.

I place everything in the include file that goes with that object. Can't
see any reason to have to remember to add containers or whatever to the
main file. Just add the 'include' line.

--
-bts
-Motorcycles defy gravity; cars just suck

Re: Same Menu On Every Page

am 10.08.2007 06:45:44 von dorayme

In article
,
"Beauregard T. Shagnasty" wrote:

> dorayme wrote:
>
> > "Beauregard T. Shagnasty" wrote:
> >> Matt White wrote:
> >>> I am creating a page with 2

's - one is a menu and one holds
> >>> the page content. The menu is the same on every page. What is the
> >>> best way to get the HTML for the menu on every page without putting
> >>> the full source on every page? I'd rather have a separate menu.html
> >>> file that gets loaded into the menu
when each page loads.
> >>> Thanks.
> >>
> >> http://allmyfaqs.net/faq.pl?Include_one_file_in_another
> >
> > I sometimes wonder what other folks do in regard to the includes, do
> > they put in all the enclosing element markup within the include or
> > leave the container explicit in the html file to remind the author
> > how the include goes. I tend to go the greedy route and put all in
> > the include. This is to show high wire courage in the face of a
> > creeping dementia.
>
> I place everything in the include file that goes with that object. Can't
> see any reason to have to remember to add containers or whatever to the
> main file. Just add the 'include' line.

In that case I am in good company - never mind that I do it with
attitude whereas you do it with plain and calm reason.

--
dorayme

Re: Same Menu On Every Page

am 10.08.2007 12:15:50 von Bernhard Sturm

Beauregard T. Shagnasty wrote:
> dorayme wrote:
>> I sometimes wonder what other folks do in regard to the includes, do
>> they put in all the enclosing element markup within the include or
>> leave the container explicit in the html file to remind the author
>> how the include goes. I tend to go the greedy route and put all in
>> the include. This is to show high wire courage in the face of a
>> creeping dementia.
>
> I place everything in the include file that goes with that object. Can't
> see any reason to have to remember to add containers or whatever to the
> main file. Just add the 'include' line.
>
sometimes it's easier to have just the actual content in the included
file, and to leave all the containers in the main file. If you follow
the idea of an 'include' you will most probably end up with this
solution: the container will not change, but the included content might
change (if you dynamically include files). Therefore you only have to
define the containers once (in the main file), and the included pages do
only contain content information. This has another advantage: it's
easier to edit such a 'container-less' page width a WYSIWIG-editor such
as dreamweaver and the like in a 'non-cms-environment' where less
experienced users are uploading only content-pages via FTP...

but there are many roads to choose :-)

bernhard

--
www.daszeichen.ch
remove nixspam to reply

Re: Same Menu On Every Page

am 10.08.2007 14:04:31 von Neredbojias

Well bust mah britches and call me cheeky, on Fri, 10 Aug 2007 10:15:50 GMT
Bernhard Sturm scribed:

> Beauregard T. Shagnasty wrote:
>> dorayme wrote:
>>> I sometimes wonder what other folks do in regard to the includes, do
>>> they put in all the enclosing element markup within the include or
>>> leave the container explicit in the html file to remind the author
>>> how the include goes. I tend to go the greedy route and put all in
>>> the include. This is to show high wire courage in the face of a
>>> creeping dementia.
>>
>> I place everything in the include file that goes with that object. Can't
>> see any reason to have to remember to add containers or whatever to the
>> main file. Just add the 'include' line.
>>
> sometimes it's easier to have just the actual content in the included
> file, and to leave all the containers in the main file. If you follow
> the idea of an 'include' you will most probably end up with this
> solution: the container will not change, but the included content might
> change (if you dynamically include files). Therefore you only have to
> define the containers once (in the main file), and the included pages do
> only contain content information. This has another advantage: it's
> easier to edit such a 'container-less' page width a WYSIWIG-editor such
> as dreamweaver and the like in a 'non-cms-environment' where less
> experienced users are uploading only content-pages via FTP...
>
> but there are many roads to choose :-)

Ultimately, a container is _always_ left in the receiving file.

--
Neredbojias
Half lies are worth twice as much as whole lies.

Re: Same Menu On Every Page

am 10.08.2007 23:01:49 von dorayme

In article ,
Bernhard Sturm wrote:

> Beauregard T. Shagnasty wrote:
> > dorayme wrote:
> >> I sometimes wonder what other folks do in regard to the includes, do
> >> they put in all the enclosing element markup within the include or
> >> leave the container explicit in the html file to remind the author
> >> how the include goes. I tend to go the greedy route and put all in
> >> the include. This is to show high wire courage in the face of a
> >> creeping dementia.
> >
> > I place everything in the include file that goes with that object. Can't
> > see any reason to have to remember to add containers or whatever to the
> > main file. Just add the 'include' line.
> >
> sometimes it's easier to have just the actual content in the included
> file, and to leave all the containers in the main file. If you follow
> the idea of an 'include' you will most probably end up with this
> solution: the container will not change, but the included content might
> change (if you dynamically include files). Therefore you only have to
> define the containers once (in the main file), and the included pages do
> only contain content information. This has another advantage: it's
> easier to edit such a 'container-less' page width a WYSIWIG-editor such
> as dreamweaver and the like in a 'non-cms-environment' where less
> experienced users are uploading only content-pages via FTP...
>
> but there are many roads to choose :-)

True about the roads and an interesting point about editing. I am
not quite sure about the point re Dreamweaver though? If one has



This is a container road, right?

--
dorayme

Re: Same Menu On Every Page

am 11.08.2007 09:39:26 von Bernhard Sturm

dorayme wrote:

>
> True about the roads and an interesting point about editing. I am
> not quite sure about the point re Dreamweaver though? If one has
>
>


>
> This is a container road, right?
>

yes. that's the road I usually take :-)
assuming you would have such a construct in the main file:


dynamically include content depending on menu context


the include file would then simply look like this:

Content only


Paragraph with content



This is much easier to maintain by someone who uses dreamweaver (or a
very simple WYSIWYG-editor) and who is only editing the content
includes. He or she will only see pure content markup no (probably)
confusing div holding it together as all containers are located in a
single file (the main file) and not distributed in various other content
files which makes my life as a webdesigner easier :-)

cheers
bernhard

--
www.daszeichen.ch
remove nixspam to reply