Jump to content
The Uniform Server Community

HOW-TO: ASP DOT NET Module for UniServer Nano 5.6.5


 Share

Recommended Posts

Tested to work with 'hello-world.aspx'.

 

Here are my steps for getting ASP to work with Uniform Server 5.6.5

 

Variables used for this how-to.

  • %top% is assumed your path to the root of UniServer Installation

  1. Temporarily rename %top%\usr\local\apache2\bin\Apache.exe to httpd.exe
  2. Download mod_aspdotnet-2.2.0.2006-setup-r2.msi
  3. Install module to %top%\usr\local\apache2 (All this does is install mod_aspdotnet.so to apache2\modules folder and adds manual to apache2\manual, and of course adds registry entries)
  4. Make a copy of mod_aspdotnet.so to _mod_aspdotnet.so
  5. Uninstall "mod_aspdotnet for Apache HTTP Server 2.2" - removing 'all' trace from the computer.
  6. Rename _mod_aspdotnet.so to mod_aspdotnet.so
  7. Rename httpd.exe back to Apache.exe
  8. Add following to the BOTTOM of your %top%\usr\local\apache2\conf\httpd.conf
    • #asp.net
      LoadModule aspdotnet_module "modules/mod_aspdotnet.so"
      AddHandler asp.net asax ascx ashx asmx aspx axd config cs csproj licx rem resources resx soap vb vbproj vsdisco webinfo
      <IfModule mod_aspdotnet.cpp>
      # Mount the ASP.NET /asp application
      AspNetMount /asp "%top%/www/asp"
      #/SampleASP is the alias name for asp.net to execute
      #"c:/SampleASP" is the actual execution of files/folders in that location
       
      # Map all requests for /asp to the application files
      Alias /asp "%top%/www/asp"
      #maps /SampleASP request to "c:/SampleASP"
      #now to get to the /SampleASP type http://localhost/SampleASP
      #It'll redirect http://localhost/SampleASP to "c:/SampleASP"
       
      # Allow asp.net scripts to be executed in the /SampleASP example
      <Directory "%top%/www/asp">
      Options FollowSymlinks ExecCGI
      Order allow,deny
      Allow from all
      DirectoryIndex index.htm index.aspx
      #default the index page to .htm and .aspx
      </Directory>
       
      # For all virtual ASP.NET webs, we need the aspnet_client files
      # to serve the client-side helper scripts.
      AliasMatch /aspnet_client/system_web/(\d+)_(\d+)_(\d+)_(\d+)/(.*) "C:/Windows/Microsoft.NET/Framework/v$1.$2.$3/ASP.NETClientFiles/$4"
      <Directory "C:/Windows/Microsoft.NET/Framework/v*/ASP.NETClientFiles">
      Options FollowSymlinks
      Order allow,deny
      Allow from all
      </Directory>
      </IfModule>
      #asp.net

[*]Restart Server

[*]Place your hello-world.aspx in folder %top%/www/asp

[*]Please provide feedback if you find a simpler method.

I have not tested beyond *BASIC* functionality of the mod. Please, if you have an involved ASP script, please try it out and share your results.

 

thanx!

Link to comment
Share on other sites

ADDITION to %top%/usr/local/apache2/conf/httpd.conf

 

 
#asp.net
LoadModule aspdotnet_module "modules/mod_aspdotnet.so"
AddHandler asp.net asax ascx ashx asmx aspx axd config cs csproj licx rem resources resx soap vb vbproj vsdisco webinfo
<IfModule mod_aspdotnet.cpp> 
 # Mount the ASP.NET /asp application
 AspNetMount /asp "%top%/www/asp"
 #/SampleASP is the alias name for asp.net to execute
 #"c:/SampleASP" is the actual execution of files/folders  in that location

 # Map all requests for /asp to the application files
 Alias /asp "%top%/www/asp"
 #maps /SampleASP request to "c:/SampleASP"
 #now to get to the /SampleASP type http://localhost/SampleASP
 #It'll redirect http://localhost/SampleASP to "c:/SampleASP"

 # Allow asp.net scripts to be executed in the /SampleASP example
 <Directory "%top%/www/asp">
Options FollowSymlinks ExecCGI
Order allow,deny
Allow from all
DirectoryIndex index.htm index.aspx
  #default the index page to .htm and .aspx
 </Directory>

 # For all virtual ASP.NET webs, we need the aspnet_client files
 # to serve the client-side helper scripts.
 AliasMatch /aspnet_client/system_web/(\d+)_(\d+)_(\d+)_(\d+)/(.*) "C:/Windows/Microsoft.NET/Framework/v$1.$2.$3/ASP.NETClientFiles/$4"
 <Directory "C:/Windows/Microsoft.NET/Framework/v*/ASP.NETClientFiles">
Options FollowSymlinks
Order allow,deny
Allow from all
 </Directory>
</IfModule>
#asp.net

 

%top%/www/asp/Hello-World.aspx

Dim I ' declare our loop index variable
%>

<%
' Start the loop telling it to loop from 1 to 5 incrementing
' I by one (which is the default) on each pass.
'
' ie. this would have done the same thing:
' For I = 1 To 5

For I = 1 To 5 Step 1
' Output our HTML and text using the value of I as
' the FONT TAG's SIZE attribute.
%>
<FONT SIZE="<%= I %>">Hello World</FONT><BR>
<%
Next ' Bounce back to the top of the loop
%>

Link to comment
Share on other sites

Sorry all. I had a brain-fart and these steps are incorrect. When installing mod_aspdotnet-2.2.0.2006-setup-r2.msi, several required files are installed in the %windir%. By Uninstalling the mod from add/remove, these files are of course removed and you will receive Apache Error:

 

mod_asp-ApacheError.png

  • RunTime Error!

  • Program: .....Apache.exe

  • This application as requested the Runtime to terminate it in an unusual way.
  • Please contact the application's supoprt team for more information.

Solution:

  1. Assuming %top% is the root of your installation folder containing the Start.exe
  2. Download and extract mod_asp.zip to %top%\mod_asp
  3. Run %top%\mod_asp\Install.bat
  4. %top%\mod_asp\Uninstall.bat will undo the previous leaving no trace on PC.

mod_asp.zip

Link to comment
Share on other sites

  • 5 years later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...