dynamicaly building includes

Discussion in 'ASP General' started by monki, Feb 25, 2004.

  1. monki

    monki Guest

    i want to generate the an include file such as

    <!--#include file="nav/nav_1.asp"-->

    but by calling the number from strNav

    <!--#include file="nav/nav_<%=strNav%>.asp"-->

    i have several combinations of quotes etc but cant get it to work!

    is there a way?

    Thanks in advance

    J
    monki, Feb 25, 2004
    #1
    1. Advertising

  2. monki

    Ray at Guest

    http://www.aspfaq.com/show.asp?id=2042

    Ray at work

    "monki" <> wrote in message
    news:Jv5%b.20360$...
    > i want to generate the an include file such as
    >
    > <!--#include file="nav/nav_1.asp"-->
    >
    > but by calling the number from strNav
    >
    > <!--#include file="nav/nav_<%=strNav%>.asp"-->
    >
    > i have several combinations of quotes etc but cant get it to work!
    >
    > is there a way?
    >
    > Thanks in advance
    >
    > J
    >
    >
    >
    >
    >
    >
    >
    Ray at, Feb 25, 2004
    #2
    1. Advertising

  3. monki

    Roy Danon Guest

    Hi,
    Only the last solution should be used.

    SSI is proccesed before ASP, this way even if the If statement includes one
    of the include files, the other one is also being proccesed.

    And FSO wastes many resources and cannot be procced as an ASP page easily.


    So what you have left is the server.execute, and server.transfer(which the
    article doesn't mention, probably because the page you transfer to doesn't
    take you back to the original one and stops proccesing at the end of the
    "transfered to" page.)


    Roy.


    "Ray at <%=sLocation%> [MVP]" <myfirstname at lane34 dot com> wrote in
    message news:OsJ1lr8%...
    > http://www.aspfaq.com/show.asp?id=2042
    >
    > Ray at work
    >
    > "monki" <> wrote in message
    > news:Jv5%b.20360$...
    > > i want to generate the an include file such as
    > >
    > > <!--#include file="nav/nav_1.asp"-->
    > >
    > > but by calling the number from strNav
    > >
    > > <!--#include file="nav/nav_<%=strNav%>.asp"-->
    > >
    > > i have several combinations of quotes etc but cant get it to work!
    > >
    > > is there a way?
    > >
    > > Thanks in advance
    > >
    > > J
    > >
    > >
    > >
    > >
    > >
    > >
    > >

    >
    >
    Roy Danon, Feb 25, 2004
    #3
  4. monki

    ljb Guest

    ljb, Feb 26, 2004
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Bisser Milanov
    Replies:
    2
    Views:
    523
    Bisser Milanov
    Jun 26, 2003
  2. Marc Nederhoff

    Adding style sheet dynamicaly

    Marc Nederhoff, Nov 5, 2003, in forum: ASP .Net
    Replies:
    2
    Views:
    411
    charles
    Nov 5, 2003
  3. moondaddy
    Replies:
    7
    Views:
    2,793
    Steven Cheng[MSFT]
    Feb 12, 2004
  4. Replies:
    2
    Views:
    410
    nfedin
    Mar 4, 2004
  5. Paul Hemans
    Replies:
    4
    Views:
    267
    Paul Hemans
    May 20, 2009
Loading...

Share This Page