Developing more than one .net site at a time under IIS 5.1 on XP Pro

S

Simon

Hi all

As I'm sure is common knowledge the version of IIS included in XP Pro is
limited in that you can only create 1 website in the IIS snap in.

As an ASP.net developer this is a pain in the arse because I can't figure
out how to stop having this fact **** up my relative urls.

When I create a virtual directory - presumably what you're supposed to do
when you're only allowed one site my relative URL's refer to the root of the
*Site* and not the root of the VirDir. As such, if i want to develop more
than one application i need to have all my images in the site root's images
folder - which is bollocks

The only other option I've figured out is to create a directory for each
project in the images directory at the root of the site - which is also
bollocks because when it comes to deployment I have either have to rearrange
all the image links in my entire site or copy the images directory to the
root of the Live Site. Either way its messy.

Now, I'm guessing Microsoft aren't so stupid as to sell a product that only
lets you develop one application at a time, but as yet my colleagues and I
havent figured out a way to do this.

If anyone can explain what I need to do to have relative URLs work correctly
that would be much appreciated. Well thats actually a misnomer. VirDirs are
doing exactly what they're supposed to do but that doesnt help me develop
more than one application at a time.

Personally I think a much better solution would be to bring the connection
limit down to about 3 or 4 concurrent users and allow the user to create as
many development sites as possible. That way microsoft can be sure that the
cut down version isnt being used to host live websites to multiple users.

I'd even prefer it if they only allowed connections from the localhost or
perhaps the local lan address range. Either way their must be many many ways
that microsoft can give developers what they need and ensure that
development environments aren't used to host actual live websites.

As I say, I'm sure there is a solution. Any advice on what it actually is
would be very much appreciated.

Thanks everyone. Any thoughts on the above would be very greatfully
received.

Kindest Regards

thechaosengine
 
K

Kristofer Gafvert

Hello,

Well, the limitation seems to be that you are only allowed to _run_ one
website at a time. You can however create several websites, but not with the
provided GUI.

You can use WMI/ADSI to create the websites, or you can use Metabase
Explorer. A tool such as this also lets you create multiple websites, and
easily switch between them:

http://www.mindxpand.be/iisadmin/
 
J

John Saunders

Simon said:
Hi all

As I'm sure is common knowledge the version of IIS included in XP Pro is
limited in that you can only create 1 website in the IIS snap in.

As an ASP.net developer this is a pain in the arse because I can't figure
out how to stop having this fact **** up my relative urls.

When I create a virtual directory - presumably what you're supposed to do
when you're only allowed one site my relative URL's refer to the root of
the *Site* and not the root of the VirDir. As such, if i want to develop
more than one application i need to have all my images in the site root's
images folder - which is bollocks

Try using a URL like "~/images/something.gif". The "~" makes the URL
relative to your application, not relative to the site.

If your application is located at http://localhost/app/, then
~/images/something.gif will be http://localhost/app/images/something.gif. If
the application is in production at http://app.company.com/, then
~/images/something.gif will be http://app.company.com/images/something.gif.

This form of URL works for all elements marked as runat="server" this means
that if you want to use it in an <img> element, you'll need to make it <img
runat="server" ...>.

John Saunders
 
J

Jeff Cochran

As I'm sure is common knowledge the version of IIS included in XP Pro is
limited in that you can only create 1 website in the IIS snap in.

As an ASP.net developer this is a pain in the arse because I can't figure
out how to stop having this fact **** up my relative urls.

The obvious solution is a development server, not running on a
workstation OS. It need not be your system, any .NET server that you
can upload files to will work.

But this may solve your immediate issues:

http://www.mindxpand.be/iisadmin/

Jeff
 
S

Simon

Thanks Guys,

I'd heard about the ~ mechanism before but havent used it.

Can anyone tell me if by marking all images as runat="server" the server
will be slowed down?

Seems like quite a rubbish solution really. At least its something though.

I'm just looking at the iisadmin app just now. Thanks for letting me know
about it

Kind Regards

Simon
 
J

Jeff Cochran

Can anyone tell me if by marking all images as runat="server" the server
will be slowed down?

I'm not sure what you're asking here. Images as in the IMG tag?
Seems like quite a rubbish solution really. At least its something though.

Rubbish how? Because you have to adhere to the restrictions of your
operating system? I'm sorry I just don't have sympathy for ".NET
Developers" who don't use a development server. It kind of just
doesn't make sense.
I'm just looking at the iisadmin app just now. Thanks for letting me know
about it

It works fine, though at some point in time you will need to test on a
server.

Jeff
 
S

Simon

Rubbish how? Because you have to adhere to the restrictions of your
operating system? I'm sorry I just don't have sympathy for ".NET
Developers" who don't use a development server. It kind of just
doesn't make sense.

I don't want your sympathy. I want Microsoft to stop crippling the web
server that it ships with its Buisiness Class operating system such that
it's a pain in the arse developing more than one application at a time. I
know why they've done it, but there are far smarter and less
counterproductive ways of making sure they don't undermine their server
class products.

I'm sorry you don't understand why people such as myself like developing on
their own local machine. I'll give you a few examples of why this *might* be
the case. There are many more reasons besides these:

1. Not everyone can afford to buy Visual Studio, Windows 2003 Server AND and
buisiness class client operating system. Why would I fork out for a
dedicated server OS when all I want to do is play with some ASP.net pages?

2. Not everyone has the necessary technical knowledge to set up a Server and
secure it appropriately.

3. Not everyone can be arsed figuring out how to get remote debugging
working when its far easier running locally.

4. Some people work on a laptop and so it doesnt make sense for them to set
up a test server when they may not be able to access it a large proportion
of the time.

5. Some people believe that given that microsoft tout XP Pro as the OS for
developers, they shouldnt then go and bugger one of the single most
important features of that OS that developers are going to want to use. Why
did they bother providing a development server if they were then going to
cripple it in a most frustrating manner. Did they not want developers to use
it or something?

6. Does you're assertion about Development/Test Servers apply to students
and hobbyists? Perhaps you've forgotton that not everyone makes software in
order to turn in a profit.

I'm not anti MS. Not by a long shot. But what they've done to IIS is just
stupid. There are numerous ways that they could have limited its
functionality such that you couldnt use the server to host live websites.
Limit on concurrent connections, restrict what IP addresses the server will
serve to and so on.

Anyway, I think they've finally come to their senses. The next version of
Visual Studio comes with a nice well integrated server to develop with.
Thankfully they havent as yet gone and trashed it making it useless for
those of us who develop more than one web application at one time.

I hope that helps explain the point of view of us pathetic ".Net Developers"
that don't/can't use a full Server Class OS simply to develop more than one
site at a time.

tce
 
L

Leythos

sh856531 said:
5. Some people believe that given that microsoft tout XP Pro as the OS for
developers, they shouldnt then go and bugger one of the single most
important features of that OS that developers are going to want to use. Why
did they bother providing a development server if they were then going to
cripple it in a most frustrating manner. Did they not want developers to use
it or something?

Developers DEVELOP website code to be run on a server, not website code
to be run on a desktop.

The ability to switch easily using XP Pro or 2000 Pro from one root site
to another is as simple as just pointing it to the next projects folder,
can be done in as little as 1 minute if you don't try.

As for the costs and other BS, you can purchase an Action Pack, if you
are a real developer you would already have the Action Pack, you can
also apply for the ISV program and then get the entire MSDN Universal
package for $402 including all the servers, tools, etc....

Any real developer would already know this.

You can also get the 120Day eval version that can be reinstalled many
times to test your application on - and most real developers already
know this.
I hope that helps explain the point of view of us pathetic ".Net Developers"
that don't/can't use a full Server Class OS simply to develop more than one
site at a time.

As a .Net developer I'm surprised that you don't know about all the
tools and items that MS provides you for almost free - you need to look
into the Action Pack and the ISV Program and stop complaining about your
own ignorance.
 
J

John Saunders

Simon said:
I don't want your sympathy. I want Microsoft to stop crippling the web
server that it ships with its Buisiness Class operating system such that
it's a pain in the arse developing more than one application at a time. I
know why they've done it, but there are far smarter and less
counterproductive ways of making sure they don't undermine their server
class products.

Simon,

The answer to "multiple web sites" was "~". You don't actually _need_
multiple web sites on your development machine in order to develop for
multiple web sites.


John Saunders
 
T

thechaosengine

Any real developer would already know this.

WTF. Who gives a rats ass what you think a real developer is and does? I
never said that I was a software developer.

Also, the reasons I gave were all completely valid. I didnt say they applied
to me though. As it happens I do know all about the tools MS provide. It's
irrelevent though - I still want to develop on my local machine and I'm
irritated that MS have bothered to put a development server in their OS and
crippled it. You're right - there are a couple of ways to get round the
problem as some helpful people have pointed out. Regardless I still think
that there are far better ways for MS to make sure the XP server isnt used
for server purposes.
As for the costs and other BS, you can purchase an Action Pack, if you
are a real developer you would already have the Action Pack, you can
also apply for the ISV program and then get the entire MSDN Universal
package for $402 including all the servers, tools, etc....

Jesus Harry Christ! Did you even both to read my last posting. I dont want
the entire f&c"£ng collection of software that MS release. Maybe $402
dollars is outside my means. Maybe it isnt. Maybe I don't want to manage a
frigging Server OS. Maybe I have a laptop and develop on the move.
As a .Net developer I'm surprised that you don't know about all the
tools and items that MS provides you for almost free - you need to look
into the Action Pack and the ISV Program and stop complaining about your
own ignorance.

Yeah and you need to understand that not everyone shares the same position
in life as you. Not everyone has a company that they can take software home
from. Not everyone wants to run server software. Not everyone can afford
servers. Not everyone is an ISV. Not everyone can afford MSDN.

Really, if you can't understand these simple principles, then it's really
only your own ignorance that you should be concerned with.

If you are actually clinically unable to engage your brain before
criticising someone in an aggressive and arrogant manner, then at least go
take some civility lessons and let the rest of us have a polite and
intelligent discussion in peace.

Thanks to anyone else who offered advice on the subject.

Very much appreciated.

Kindest Regards

tce
 
T

thechaosengine

Hi John,

I'd heard of the ~ approach but I'd also heard that quite a few people were
having problems with it. I havent tried it yet. I like the iisadmin tool
mentioned above though because it lets you flick between sites very quickly.
I think I prefer that because then I can leave all my image URLs starting
with / instead of ~/.

It's probably silly but using /images just feels more natural to me.

Thanks for your help

tce
 
L

Leythos

sh856531 said:
Yeah and you need to understand that not everyone shares the same position
in life as you. Not everyone has a company that they can take software home
from. Not everyone wants to run server software. Not everyone can afford
servers. Not everyone is an ISV. Not everyone can afford MSDN.

I got news for you, MS did provide a means for you to develop websites
on their 2000 Prof and XP Prof systems, and you wine about it. No one
says you have to use the IDE, in fact, many good coders still use
Notepad for designing .net sites.

As for not being able to afford servers, you can run Windows 2000 Server
and Windows 2003 on just about any laptop. You can also get 120 Eval
copies of their servers for the cost of the media alone.

As for not being an ISV, Anyone that wants to be an ISV can be one, and
the MSDN comes with the ISV membership for free.

So, now that you don't have any excuses, don't want to do one site at a
time, don't want to switch between root sites in under 30 seconds, you
appear to only be a winey little brat, what's your excuse now?
 
J

Jeff Cochran

I don't want your sympathy. I want Microsoft to stop crippling the web
server that it ships with its Buisiness Class operating system such that
it's a pain in the arse developing more than one application at a time.

Have you told *them*?
I
know why they've done it, but there are far smarter and less
counterproductive ways of making sure they don't undermine their server
class products.

These discussions come up a couple dozen times a year. In the last
decade, it hasn't changed the way the system works. And by far the
vast majority of users of all sorts have no problems with this issue.
I'm sorry you don't understand why people such as myself like developing on
their own local machine. I'll give you a few examples of why this *might* be
the case. There are many more reasons besides these:

1. Not everyone can afford to buy Visual Studio, Windows 2003 Server AND and
buisiness class client operating system. Why would I fork out for a
dedicated server OS when all I want to do is play with some ASP.net pages?

You don't have to. There are several free .NET editors and even
environments which don't requires an OS with web server capability.
And nobody has ever said you need to buy a server, .NET hosting is
relatively inexpensive for anyone serious about developing, as a hobby
*or* profession.
2. Not everyone has the necessary technical knowledge to set up a Server and
secure it appropriately.

Then how are they setting up and securing their "business class
operating system" with a web server? And whay aren't they using a
hosted service?
3. Not everyone can be arsed figuring out how to get remote debugging
working when its far easier running locally.

There's no reason you can't work locally.
4. Some people work on a laptop and so it doesnt make sense for them to set
up a test server when they may not be able to access it a large proportion
of the time.

There's no reason they have to.
5. Some people believe that given that microsoft tout XP Pro as the OS for
developers, they shouldnt then go and bugger one of the single most
important features of that OS that developers are going to want to use. Why
did they bother providing a development server if they were then going to
cripple it in a most frustrating manner. Did they not want developers to use
it or something?

While I've never seen XP "touted" as being for developers, Microsoft
kind of expects that developers will acquire and use the tools they
need to do their developing.
6. Does you're assertion about Development/Test Servers apply to students
and hobbyists? Perhaps you've forgotton that not everyone makes software in
order to turn in a profit.

Students definitely. If you're learning to develop, you should be
learning to develop correctly. Hobbyists in all hobbies face some
sort of costs. Those who cannot affor the costs participate in the
hobbies in different ways.
I'm not anti MS. Not by a long shot. But what they've done to IIS is just
stupid. There are numerous ways that they could have limited its
functionality such that you couldnt use the server to host live websites.
Limit on concurrent connections, restrict what IP addresses the server will
serve to and so on.

Though there's no real reason they should. Except that you want to
work on multiple sites simultaneously.
Anyway, I think they've finally come to their senses. The next version of
Visual Studio comes with a nice well integrated server to develop with.
Thankfully they havent as yet gone and trashed it making it useless for
those of us who develop more than one web application at one time.

Your #1 was that not everyone could afford to by Visual Stduio...
I hope that helps explain the point of view of us pathetic ".Net Developers"
that don't/can't use a full Server Class OS simply to develop more than one
site at a time.

I understand the point. I understand the limitations. You do as
well, you just don't want to live within the restrictions of your
budget ability.

Microsoft provides many resources for developers and students to ease
the costs. Academic versions of software are cheap. 120 day
evaluation copies are available for the cost of shipping. Developer
versions and developer support tools are available in several
different combinations. Tools to develop .NET apps without an
operating system having a web server capability exist. The ability
exists to develop a full web application in .NET and test it on a
workstation OS prior to deployment on a server.

But none of these meet your *wants*. And that's something that won't
change, whether you accept it or not. We've given you options that
may help you further, but you won't find a lot of support for the rest
of your desires. And if you truly desire these changes, Microsoft
does listen. Contact them.

Jeff
 
T

thechaosengine

I'm not anti MS. Not by a long shot. But what they've done to IIS is just
Though there's no real reason they should. Except that you want to
work on multiple sites simultaneously.

I know many people who like to work locally without the expense and
complexity of a second server or having to run a server OS as their local
machines OS. I think that satisfying these many thousands of users would be
a good enough reason for them to "want to"

Your #1 was that not everyone could afford to by Visual Stduio...

My #1 was that not everyone can afford VS AND a Local OS AND a Server
operating system AND potentially an additional computer.
I understand the point. I understand the limitations. You do as
well, you just don't want to live within the restrictions of your
budget ability.

You've made the mistake of thinking that the 5/6 points I raised in my
earlier post applied to me. I think one at most applies to me. The others
come from prior experiences and from the experiences of friends and people
I've talked to about it online.
As it happens I can afford the test server - I just choose not to use it
sometimes.
Microsoft provides many resources for developers and students to ease
the costs. Academic versions of software are cheap. 120 day
evaluation copies are available for the cost of shipping.

Whether something is cheap is largely a matter of opinion and relativity.
Whilst VS 2003 AE is a lot cheaper than the professional edition, its still
£100 or so.
Relatively speaking it is cheap. But when you are living off of borrowed
money and having to buy shed loads of software from Macromedia and Adobe,
nothing is cheap.

I was in this situation quite recently. This was when I started getting
frustrated at the current set up.
But none of these meet your *wants*.

It no longer needs to meet my wants - I have an interim solution that will
do for now and Microsoft have finally realised the it would be a much more
integrated development environment if VS came with its own limited .net
server. This will ship with VS 2005 and is already shaping up well. I've
been doing beta testing on it for a while.
We've given you options that may help you further, but you won't find a
lot of support for the rest
of your desires.

On the contrary why would MS change the situation as they are doing if they
didnt think the existing implementation wasnt good enough. Just for fun?
I know for a fact that MS has taken a lot of requests to improve the current
situation as far as local development is concerned, and thats what they're
doing.
And if you truly desire these changes, Microsoft
does listen. Contact them.

As mentioned - I already have and you're right - they do listen - if enough
people kick up a stink.

The one last thing I just want to mention is with regards to what happened
when I discovered this limitation as a student.

I had the Home version of the OS and was most pissed that I couldn't make
websites using ASP.Net even though I had forked out the cash for the
expensive IDE. When I asked why this was the case, posters like yourself
told me that I was using a Kiddie OS and that it served me right. "Real Men
use the Proffessional OS". Stupid pathetic me. This was before the Cassini
project btw. I asked MS what I could do and they said nothing but that they
were looking at other options to deal with the situation.. Their reason for
not supporting IIS on the home os was because developers work for businesses
and businesses want the more business oriented features of the PRO OS. Fair
enough. It might arguably be a security hazard to have IIS on a home OS as
well (even though you would need the presence of mind to go install it
manually first). They also said that Pro was their preferred OS for
developers. Their words, not mine.

You also have to ask yourself - if MS didnt get a lot of requests and
support for local development - why would they insist that you have ASP.net
installed locally on the installed IIS server that they provide? If I were
running it remotely I wouldnt need to install IIS.

It seems then, given the above and what MS are doing in VS 2005 that MS DO
have a lot of people wanting to work local after all. Otherwise why would
they go to all the trouble of releasing IIS on the Business/Developer OS and
greatly enchancing the features of VS for users that want to work locally.

As I said earlier. I have an interim solution until VS 2005 comes out so I'm
happy enough. I do still think its a shame that it required a third party
tool to make the server as easy as it should have been in the first place
 

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

No members online now.

Forum statistics

Threads
473,982
Messages
2,570,186
Members
46,740
Latest member
JudsonFrie

Latest Threads

Top