Solved

Virtual Pathing Problem

Posted on 2008-10-02
3
164 Views
Last Modified: 2012-05-05
I am moving a website from a dedicated server to a server that will host multiple sites. Most of the path descriptions on the dedicated server code are relative:
 (i.e. <!-- #include virtual =  "/include/somefile.aps" --> or <img src = "/images/pixel.gif" )
and the defalt page is at the root (i.e.  wwwroot.default.asp). Now when I move a copy of the code to the new server, is will not be at root but in a subdirectory (i.e. wwwroot/myweb/default.asp).  All of the paths fail and the only way I can get the include to work is to change it to:
 <!-- #include file = "../../include/somefile.asp" --> and <img src="../../images/pixel.gif">.
 Do I have to change all of the pathing on my code??  Ugly thought!
0
Comment
Question by:kevbob650
  • 2
3 Comments
 
LVL 5

Expert Comment

by:lodar123
ID: 22626564
to my knowledge... its the ugly answer :) so yes
0
 

Author Comment

by:kevbob650
ID: 22626739
So there's no magic "virtual directory" or way to trick IIS? This is a big site with hundreds of pages.
0
 
LVL 5

Accepted Solution

by:
lodar123 earned 125 total points
ID: 22626904
i guess you could create a virtual directory, or virtual domain name and the put the url for the include. I never tried that option though.  I used ASP most of the time and used global variables for my paths then just needed to add the file name
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now