HOW TO.....insert a variable value in an INCLUDE fiel

Discussion in 'ASP General' started by Mike Combe, Sep 21, 2003.

  1. Mike Combe

    Mike Combe Guest

    Hello All,


    Given.....
    <!--#include file="htm1.asp" -->


    Any ideas how to make the 'htm1.asp' a variable name?

    Say at one time we want to use 'htm1.asp' and another
    time we want to use 'htm2.asp' as the include file.

    Any ideas?


    --- Mike
     
    Mike Combe, Sep 21, 2003
    #1
    1. Advertising

  2. Mike Combe

    GAT Guest

    try this ???

    <!--#include file="<% =varName%>" -->




    "Mike Combe" <> wrote in message
    news:...
    > Hello All,
    >
    >
    > Given.....
    > <!--#include file="htm1.asp" -->
    >
    >
    > Any ideas how to make the 'htm1.asp' a variable name?
    >
    > Say at one time we want to use 'htm1.asp' and another
    > time we want to use 'htm2.asp' as the include file.
    >
    > Any ideas?
    >
    >
    > --- Mike
     
    GAT, Sep 21, 2003
    #2
    1. Advertising

  3. Mike Combe

    Evertjan. Guest

    Mike Combe wrote on 21 sep 2003 in microsoft.public.inetserver.asp.general:
    > Given.....
    > <!--#include file="htm1.asp" -->
    >
    >
    > Any ideas how to make the 'htm1.asp' a variable name?
    >
    > Say at one time we want to use 'htm1.asp' and another
    > time we want to use 'htm2.asp' as the include file.


    Bad idea, you cannot.


    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Sep 21, 2003
    #3
  4. Mike Combe

    Evertjan. Guest

    GAT wrote on 21 sep 2003 in microsoft.public.inetserver.asp.general:

    > try this ???
    >
    > <!--#include file="<% =varName%>" -->
    >


    Nonsense, the include is inserted before the asp rendering.

    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Sep 21, 2003
    #4
  5. Mike Combe

    Bob Barrows Guest

    Mike Combe wrote:
    > Hello All,
    >
    >
    > Given.....
    > <!--#include file="htm1.asp" -->
    >
    >
    > Any ideas how to make the 'htm1.asp' a variable name?
    >
    > Say at one time we want to use 'htm1.asp' and another
    > time we want to use 'htm2.asp' as the include file.
    >
    > Any ideas?
    >
    >
    > --- Mike


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

    HTH,
    Bob Barrows
     
    Bob Barrows, Sep 21, 2003
    #5
    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. Danny Anderson
    Replies:
    5
    Views:
    517
    Victor Bazarov
    Aug 15, 2003
  2. Andreas Bogenberger
    Replies:
    3
    Views:
    958
    Andreas Bogenberger
    Feb 22, 2008
  3. Tradeorganizer
    Replies:
    5
    Views:
    178
    Tradeorganizer
    Jan 31, 2007
  4. fiel reading and processing

    , Apr 23, 2006, in forum: Perl Misc
    Replies:
    6
    Views:
    97
    robic0
    Apr 24, 2006
  5. Replies:
    4
    Views:
    172
    Gomolyako Eduard
    Oct 18, 2005
Loading...

Share This Page