Virtual Directories

M

Mr Struggler

Hi Folks,

OK, I have a IIS Server running in my house and as I have a static IP
Address I host a web site from it. I have two virtual mapping to the
directory in where it is stored. so www.mydomain.net or mydomain.net will
arrive at the same web site wwwroot\myWebsite

This works fine except that I am using a javascript menu system. The problem
here is that when I build and launch the site from my PC, I get

localhost/myWebsite/default.aspx

When I visit my site server i of course get

www.myDomain.net/default.aspx

This makes the subdirectory invisible to the user which is what I want.

The problem is I need to apply the same redirection to my local machine
otherwise its expecting to see code either with or without the \myWebsite
depending on where the application is run from.

Cheers
 
C

Cowboy \(Gregory A. Beamer\)

You need a site at root. THis means binding an additional IP address to a
card in the machine and making a new website instead of a virtual directory.
Then, everything will map the same way.

The other way around this is adding the dynamic bits that make the sites
different by embedding in the JavaScript at runtime.
 
J

Jon Paal

When you set up the local virtual site on your IIS, it should be to folder:

"/myWebsite"

when you launch a page it should return

"localhost/default.aspx"
 
M

Mr Struggler

Thanks for the advice. I took it and re-wrote the javascript menu to
compensate for the two environments.

Regards
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,982
Messages
2,570,186
Members
46,744
Latest member
CortneyMcK

Latest Threads

Top