Server Side Includes that are Hard Pathed

Results 1 to 2 of 2

Thread: Server Side Includes that are Hard Pathed

  1. #1
    Join Date
    Dec 1969

    Default Server Side Includes that are Hard Pathed

    I have tried using the virtual include to include a file that is located in a folder on my C drive. The file is located at:<BR><BR> C:IncludesIntro.asp<BR><BR>and this Did Not Work!<BR>&#060;!--#include virtual="/Includes/Intro.asp"--&#062;<BR><BR>My web page is located at:<BR>C:WebPagesWebPage1Default.asp<BR>and I have another webpage at:<BR>C:WebPagesWebPage2Default.asp<BR><BR>How can I get both of these web page to include the file listed above at the location given in the second sentence of this message? It is important that I have a hard path, so I can move my web folder anywhere, and not have to change the includes.<BR>

  2. #2
    Join Date
    Dec 1969

    Default You can't

    you can&#039;t to my knowledge. But if you want a workaround for this, just setup a virtual directory called includes in each site and point it to your c:includes folder. You will obviously need access to the server to do this. Then from both pages you can share the includes with &#060;!--#include virtual="/Includes/Intro.asp"--&#062; and they will pull from the same file.<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts