Examples of building web site navigation for ASP.NET site?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jason Hanks

    Examples of building web site navigation for ASP.NET site?

    Hi, are there any examples that demonstrate how to build an ASP.NET page
    with consistent parts of the layout, such as page headers, footers, and
    navigation links (such as going into each section like Products, Company,
    Services, etc)?

    I know there are controls that you can use to build menus like ASP.NET menu.
    But I'm talking more about the graphical elements and layout that needs to
    be part of each page.

    For example when I designed my site in old ASP I had include files. So I
    did something like this from each page:

    <!-- #INCLUDE VIRTUAL="/top-of-page.inc"-->
    main page content goes here
    <!-- #INCLUDE VIRTUAL="/bottom-of-page.inc"-->

    But in ASP.NET that doesn't seem like a concept that works. Instead it
    seems like maybe I have a common class or something that will write out my
    headers and footers so I have a consistent look and feel, and so I can just
    change nav links in one place as I make changes to the site instead of
    having to change it on every page like I would if I had embedded it. Any
    examples of how to handle this the "correct" or ideal way in ASP.NET would
    be MUCH APPRECIATED. Thank you.


  • pmb

    #2
    Re: Examples of building web site navigation for ASP.NET site?

    You can implement a so-called "User Control". It works approximately
    like this:

    <%@ Register TagPrefix="myct l" TagName="Footer " Src="footer.asc x" %>
    .... Later on: ...
    <myctl:Footer id="footer1" runat="server" />

    Use the keyword "User Control" to find it in the documentation pages.

    Good luck!

    On Thu, 10 Jun 2004 18:17:22 -0400, "Jason Hanks" <no-email@acct.com>
    wrote:
    [color=blue]
    >Hi, are there any examples that demonstrate how to build an ASP.NET page
    >with consistent parts of the layout, such as page headers, footers, and
    >navigation links (such as going into each section like Products, Company,
    >Services, etc)?
    >
    >I know there are controls that you can use to build menus like ASP.NET menu.
    >But I'm talking more about the graphical elements and layout that needs to
    >be part of each page.
    >
    >For example when I designed my site in old ASP I had include files. So I
    >did something like this from each page:
    >
    ><!-- #INCLUDE VIRTUAL="/top-of-page.inc"-->
    >main page content goes here
    ><!-- #INCLUDE VIRTUAL="/bottom-of-page.inc"-->
    >
    >But in ASP.NET that doesn't seem like a concept that works. Instead it
    >seems like maybe I have a common class or something that will write out my
    >headers and footers so I have a consistent look and feel, and so I can just
    >change nav links in one place as I make changes to the site instead of
    >having to change it on every page like I would if I had embedded it. Any
    >examples of how to handle this the "correct" or ideal way in ASP.NET would
    >be MUCH APPRECIATED. Thank you.
    >[/color]

    Comment

    • Jason Hanks

      #3
      Re: Examples of building web site navigation for ASP.NET site?

      Are there any samples like in the VB.NET resource kit or somewhere else
      somecan can point me to where I can get a good look at how the site
      navigation html source can be centralized in one location/class/file?


      "pmb" <pacmanbert@tok yo.com> wrote in message
      news:hlqhc0p88o lsg2rd3f3gk74o2 0pl2snv68@4ax.c om...[color=blue]
      > You can implement a so-called "User Control". It works approximately
      > like this:
      >
      > <%@ Register TagPrefix="myct l" TagName="Footer " Src="footer.asc x" %>
      > ... Later on: ...
      > <myctl:Footer id="footer1" runat="server" />
      >
      > Use the keyword "User Control" to find it in the documentation pages.
      >
      > Good luck!
      >
      > On Thu, 10 Jun 2004 18:17:22 -0400, "Jason Hanks" <no-email@acct.com>
      > wrote:
      >[color=green]
      > >Hi, are there any examples that demonstrate how to build an ASP.NET page
      > >with consistent parts of the layout, such as page headers, footers, and
      > >navigation links (such as going into each section like Products, Company,
      > >Services, etc)?
      > >
      > >I know there are controls that you can use to build menus like ASP.NET[/color][/color]
      menu.[color=blue][color=green]
      > >But I'm talking more about the graphical elements and layout that needs[/color][/color]
      to[color=blue][color=green]
      > >be part of each page.
      > >
      > >For example when I designed my site in old ASP I had include files. So I
      > >did something like this from each page:
      > >
      > ><!-- #INCLUDE VIRTUAL="/top-of-page.inc"-->
      > >main page content goes here
      > ><!-- #INCLUDE VIRTUAL="/bottom-of-page.inc"-->
      > >
      > >But in ASP.NET that doesn't seem like a concept that works. Instead it
      > >seems like maybe I have a common class or something that will write out[/color][/color]
      my[color=blue][color=green]
      > >headers and footers so I have a consistent look and feel, and so I can[/color][/color]
      just[color=blue][color=green]
      > >change nav links in one place as I make changes to the site instead of
      > >having to change it on every page like I would if I had embedded it. Any
      > >examples of how to handle this the "correct" or ideal way in ASP.NET[/color][/color]
      would[color=blue][color=green]
      > >be MUCH APPRECIATED. Thank you.
      > >[/color]
      >[/color]


      Comment

      Working...