Publish an ASP Web site with Apache

Source: Internet
Author: User
Tags soap

Since the server needs to publish several web sites such as JSP, PHP and ASP, Apache is sure to support JSP and PHP. In view of the open spirit of Apache, ASP. NET should also support, so Google. The configuration steps are as follows:

1. Download ASP. NET Parsing module (mod_aspdotnet)

: http://sourceforge.net/projects/mod-aspdotnet/, direct installation. In the. \apache\modules directory, a module named Mod_aspdotnet.so appears.

2. Configure Apache to enable it to support this module

Create the configuration file mod_aspdotnet.conf, saved in the \apache\conf directory, with the following contents:

[Plain]View PlainCopy
  1. # ASP.
  2. LoadModule Aspdotnet_module modules/mod_aspdotnet.so
  3. AddHandler ASP asax ascx ashx asmx aspx axd config cs csproj licx rem resources resx soap vb vbproj vsdisco webinfo
  4. <ifmodule mod_aspdotnet.cpp>
  5. # Mount The ASP. Example Application
  6. Aspnetmount/aspnet "F:/demo"
  7. # MAP all requests for/active to the application files
  8. Alias/aspnet "F:/demo"
  9. # Allow ASP. Scripts to being executed in the active example
  10. <directory "F:/demo" >
  11. Options FollowSymLinks execcgi
  12. Order Allow,deny
  13. Allow from all
  14. DirectoryIndex index.aspx Default.aspx index.html
  15. </Directory>
  16. # for all virtual ASP webs, we need the aspnet_client files
  17. # to serve the Client-side helper scripts.
  18. aliasmatch/aspnet_client/system_web/(\d+) _ (\d+) _ (\d+) _ (\d+)/(. *) \ "C:/windows/microsoft.net/framework/v$1.$2.$3 /asp. Netclientfiles/$4 "
  19. <directory "C:/windows/microsoft.net/framework/v*/asp.netclientfiles" >
  20. Options FollowSymLinks
  21. Order Allow,deny
  22. Allow from all
  23. </Directory>
  24. </IfModule>

Note: The following two sentences cannot be wrapped, and the site local path cannot contain Chinese characters.

AddHandler ASP asax ascx ashx asmx aspx axd config cs csproj licx rem resources resx soap vb vbproj vsdisco webinfo

aliasmatch/aspnet_client/system_web/(\d+) _ (\d+) _ (\d+) _ (\d+)/(. *) \ "C:/windows/microsoft.net/framework/v$1.$2.$3 /asp. Netclientfiles/$4 "

And then add the httpd.conf file to the end

[Plain]View PlainCopy
    1. #mod_aspdotnet Support
    2. Include conf/mod_aspdotnet.conf

Finally, restart Apache.

3. Testing

Write the test page default.aspx, and put it in the "F:/demo" directory

Input test page: http://localhost:8080/aspnet/default.aspx

Publish an ASP Web site with Apache

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.