DotNetNuke Tip #15, Running a webservice inside of a DNN site.

Published Monday, August 21, 2006 1:58 PM

Perhaps you need to run a webservice inside an instance of DotNetNuke. If you've tried by just copying the webservice directory out there you've probably been frustrated with the result.

The fix is pretty darn simple. First thing, create a virtual directory in IIS for your web service folder.

Second, copy the BIN files from the DotNetNuke/bin folder to the webservice/bin folder.

In the webservice web.config file add the following to System.web

<httpModules>

<clear />

</httpModules>

That will clear out the httpModules that DNN loads, thus allowing your webservice to run on it's own.

<clear />

</httpModules>

That will clear out the httpModules that DNN loads, thus allowing your webservice to run on it's own.

 

12/4/2010 An update to this blog post

I found another useful resource for IIS7 and getting a virtual directory to run Under DotNetNuke, follow the instructions on this blog post.

Comments

# Nathan said on Wednesday, April 04, 2007 12:29 PM

I tried adding the lines to my web.config for a Screwturn wiki running inside of DNN, but it doesn't clear out the httpModules that DNN loads.

# Paige said on Thursday, June 05, 2008 4:11 PM

Using DNN 4.8.3 here is everything that I needed to add to my web.config:

     <httpModules>

       <remove name="ScriptModule"  />

       <remove name="Compression"  />

       <remove name="RequestFilter"  />

       <remove name="UrlRewrite"  />

       <remove name="Exception"  />

       <remove name="UsersOnline"  />

       <remove name="DNNMembership"  />

       <remove name="Personalization" />

     </httpModules>

     <httpHandlers>

       <remove verb="*" path="*.captcha.aspx"/>

       <remove verb="*" path="LinkClick.aspx"/>

       <remove verb="*" path="RSS.aspx"/>

       <remove verb="*" path="Logoff.aspx"/>

       <remove verb="*" path="*_AppService.axd"/>

       <remove verb="GET,HEAD" path="ScriptResource.axd"/>-->

     </httpHandlers>

     <pages>

       <namespaces>

         <remove namespace="DotNetNuke.Services.Localization"/>

         <remove namespace="DotNetNuke.Entities.Users"/>

         <remove namespace="DotNetNuke"/>

         <remove namespace="DotNetNuke.Common"/>

         <remove namespace="DotNetNuke.Data"/>

         <remove namespace="DotNetNuke.Framework"/>

         <remove namespace="DotNetNuke.Modules"/>

         <remove namespace="DotNetNuke.Security"/>

         <remove namespace="DotNetNuke.Services"/>

         <remove namespace="DotNetNuke.UI"/>

         <remove namespace="DotNetNuke.Entities.Portals"/>

         <remove namespace="DotNetNuke.Common.Utilities"/>

         <remove namespace="DotNetNuke.Services.Exceptions"/>

         <remove namespace="DotNetNuke.Entities.Tabs"/>

       </namespaces>

     </pages>

Please note that this was for a web service in a subdirectory.  I have installed Screwturn in a DNN subdirectory before.  I will try to find that web.config

This Blog

Syndication