Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

.NET Forum


You are currently viewing our .NET Forum as a guest. Please register to participate.
Login



Reply
.net 3.5, c# and IIS: How do Imake everything run together ?
Old 02-13-2008, 06:28 PM .net 3.5, c# and IIS: How do Imake everything run together ?
tripy's Avatar
Do not try this at home!

Posts: 3,621
Name: Thierry
Location: I'm the uber Spaminator !
Trades: 0
Hello peoples,

Php expert, but IIS noob here....

I'm currently learning c# by porting a PHP class to .net, with the last .net 3.5 version of the framework.

Everything's fine, but I struggle to a simple thing: how to install and configure IIS on windows XP to run ASP.Net applications ?

When I've installed the Visual Studio Express edition, a small web server comes bundled with it (ASP .net development server) , which is launched when I ask VS to display the site.
So far, Ok.

But now, I would like to map every "/xsl/" requests to a resource subfolder of my project, how do I do that ?

In apache, I was using
Code:
RewriteRule ^xsl/(.*)$        /libs/xml/xsl.php?path=$1   [NC,L]
I have found this page:
http://msdn2.microsoft.com/en-us/library/ms972974.aspx
Which is at the same time so overloaded with informations and so sparse about where and how to implement them that I don't understand the way to go...

I thought that using the ISAPI level of rewritting would be the simplier, so, as advised by the article, I have added the module and the handler
Code:
<httpHandlers>
            <remove verb="*" path="*.asmx"/>
            <add verb="*" path="*.asmx" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add verb="*" path="*_AppService.axd" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
            <add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false"/>
      <add verb="*" path="*.aspx" type="URLRewriter.RewriterFactoryHandler, URLRewriter" />
        </httpHandlers>
        <httpModules>
            <add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
      <add type="URLRewriter.ModuleRewriter, URLRewriter" name="ModuleRewriter" />
    </httpModules>
Now, the article says that I must add a <rewriterConfig> section, but where ???
At which level into that web.config file should I put it. I've tried several levels (sibling of the modules and handler definition, and as a sibling of the first level) but it just won't do...

Am I missing something obvious ???
Oh, and thanks not flaming me (too much) about my noobness....
I'm not used to it anymore... It's what happens when you become the reference amongst your colleagues and you start a whole new language again...
Thanks.

Thierry.
__________________
Only a biker knows why a dog sticks his head out the window.
tripy is offline
Reply With Quote
View Public Profile Visit tripy's homepage!
 
 
Register now for full access!
Old 05-21-2008, 03:40 AM Re: .net 3.5, c# and IIS: How do Imake everything run together ?
Average Talker

Posts: 24
Trades: 0
XP professional disc should comes with IIS. Just install the IIS and make virtual dir there....everything should work fine. do some configuration in IIS if needed.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
idisplayforless is offline
Reply With Quote
View Public Profile Visit idisplayforless's homepage!
 
Old 06-08-2008, 04:12 AM Re: .net 3.5, c# and IIS: How do Imake everything run together ?
RabidSniper's Avatar
Skilled Talker

Posts: 57
Name: Jesse
Location: Phoenix, AZ
Trades: 0
Right... In XP, use the ADD REMOVE PROGRAMS Admin option and then select Add / Remove windows components. DRill down and install IIS..

After IIS install, download and install all of the .NET frameworks.. make sure you get 2.0, 3.0 and 3.5 and all the Service packs using windows update or something. (thats really the quickest way).

ONce that is done, you can use the IIS MMC Console to create a new virtual directory and "Application". Make sure you go into the .NET Framework tab of the web application properties pane and select Framework 2.0 (it defaults to 1.1).

At that point, IIS will read and understand the web.config file put into its directory.
For example, if I create a new web application in IIS called MYAPP, It would default to pointing to something like c:\inetpub\wwwroot\MYAPP

In that directory, you could manually place (or use some sort of tool like Visual Studio Web Developer) to create a web.config file, that would then do the URL rewriting that the article you linked to, describes.

Hope that helps.

Last edited by RabidSniper; 06-08-2008 at 04:14 AM..
RabidSniper is offline
Reply With Quote
View Public Profile
 
Old 06-10-2008, 03:53 PM Re: .net 3.5, c# and IIS: How do Imake everything run together ?
Learning Newbie's Avatar
Defies a Status

Latest Blog Post:
Astounding Republican Paranoia
Posts: 5,662
Name: John Alexander
Trades: 0
I have to admit, http handlers and the like aren't an area of IIS I'm very familiar with. How goes the progress?
__________________

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
Learning Newbie is offline
Reply With Quote
View Public Profile
 
Old 06-10-2008, 05:31 PM Re: .net 3.5, c# and IIS: How do Imake everything run together ?
tripy's Avatar
Do not try this at home!

Posts: 3,621
Name: Thierry
Location: I'm the uber Spaminator !
Trades: 0
I have to say that I've paused that project a couple of month ago. A necro thread monger revived it.

And since my most advanced service is done in python, I'm currently rewriting a whole site with Django.
It's not as simple as with PHP (but probably because I have almost 10 years of PHP after me) but I'm starting to get where I want.

The only drawback, is that every web framework (or almost) in python assume that you want to use an ORM.
And when 80% of the business logic is in stored procedures, it's a bit like swimming against the river...
__________________
Only a biker knows why a dog sticks his head out the window.
tripy is offline
Reply With Quote
View Public Profile Visit tripy's homepage!
 
Reply     « Reply to .net 3.5, c# and IIS: How do Imake everything run together ?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.43914 seconds with 12 queries