Windows下LAMP集成环境AppServ虚拟目录配置方法及错误处理
2012-06-11 11:23
921 查看
LAMP集成环境AppSerLAMP集成环境AppServ虚拟目录配置方法 http://anjor.iteye.com/blog/9097801.首先下载AppServ安装包,地址:http://cdnetworks-kr-2.dl.sourceforge.net/project/appserv/AppServ%20Open%20Project/2.5.10/appserv-win32-2.5.10.exe 2.安装完成后,开始配置虚拟目录 3.打开appserv的安装目录,找到httpd.conf文件,分别去掉下面两行文字前面的#号。 #LoadModule vhost_alias_module modules/mod_vhost_alias.so 去掉#意思是启用apache的虚拟主机功能。 #Include conf/extra/httpd-vhosts.conf 去掉这一行的#意思是从conf/extra/httpd-vhosts.conf这个文件导入虚拟主机配置。 4.打开extra目录内的httpd-vhosts.conf文件,在文件底部加入自己要加的虚拟主机的信息。 首先将最低下一行代码去掉: Java代码 <VirtualHost *:80> ServerAdmin webmaster@dummy-host.appservnetwork.com DocumentRoot /www/docs/dummy-host.appservnetwork.com ServerName dummy-host.appservnetwork.com ServerAlias www.dummy-host.appservnetwork.com ErrorLog logs/dummy-host.appservnetwork.com-error_log CustomLog logs/dummy-host.appservnetwork.com-access_log common </VirtualHost> <VirtualHost *:80> ServerAdmin webmaster@dummy-host2.appservnetwork.com DocumentRoot /www/docs/dummy-host2.appservnetwork.com ServerName dummy-host2.appservnetwork.com ErrorLog logs/dummy-host2.appservnetwork.com-error_log CustomLog logs/dummy-host2.appservnetwork.com-access_log common </VirtualHost> 然后加入自己需要的虚拟努力配置: Java代码 <VirtualHost *:80> ServerAdmin anjor_web@163.com DocumentRoot "D:/AppServ/www/ikaku_html" ServerName www.ikaku.com ErrorLog D:/AppServ/www/ikaku_html/error.log </VirtualHost> <VirtualHost *:80> ServerAdmin anjor_web@163.com DocumentRoot "D:/AppServ/www/ikaku_design" ServerName static.ikaku.com ErrorLog D:/AppServ/www/ikaku_design/error.log </VirtualHost> 有些可能需要使用目录权限: Java代码 <Directory D:/> Options Indexes AllowOverride AuthConfig FileInfo Order allow,deny Allow from all </Directory> 5.修改本机hosts文件,方便解析域名,hosts文件地址:C:\WINDOWS\system32\drivers\etc 加入要解析的域名 127.0.0.1 static.ikaku.com www.ikaku.com ######################################################配置好启动apache过程中出现错误提示:1、(OS 10048)通常每个套接字地址(协议/网络地址/端口)只允许使用一次。 : make_sock: could not bind to address 0.0.0.0:1213no listening sockets available, shutting downUnable to open logs解决方法:1:通过 netstat -anb 查看端口占用情况,关闭调用相关端口的进程 通过查看发现iis默认网站打开了占用了80端口,停止掉好了。2:通过 修改conf/httpd.conf 中相应的监听端口来处理。=====================================================2、弹出窗口提示:找不到php_mbstring.dll,apache无法启动!解决方法:或提示找不到php_mbstring.dll,都可以用下面的方法解决.mb_开头的函数是为了解决像utf-8这样多字节字符的截取与长度等操作的,如果直接用substr则常出现最后一个字符的乱码(即截取了半个汉字)首先安装php_mbstring.dll,它是放在php目录的 ext文件夹下的,确保在php.ini文件中加载extension=php_exif.dll前先加载extension=php_mbstring.dll,即:extension=php_mbstring.dll 在前extension=php_exif.dll 在后.否则在命令行启动时总会提示:“找不到php_mbstring.dll”.####################################################另外一个apache虚拟主机配置样例:NameVirtualHost *:80<VirtualHost *:80> ServerAdmin 123456@qq.comDocumentRoot D:\AppServ\www\ServerName new.0574-office.comServerAlias new.0574-office.comDirectoryIndex index.html index.htm index.php<Directory "D:\AppServ\www\"> AllowOverride None Options FollowSymLinks Order allow,deny Allow from all</Directory></VirtualHost>#########################################其他参考资料:windows下利用apache配置WEB站点 - .\Best - 51CTO技术博客 http://best0.blog.51cto.com/444987/98793PHP环境配置:Windows下AppServ配置与安装使用教程 | PHP网站开发-PHP教程-LeapSoul.CN http://www.leapsoul.cn/?p=292v虚拟目录配置方法
相关文章推荐
- LAMP集成环境AppServ虚拟目录配置方法
- “在应用程序级别之外使用注册为 allowDefinition=’MachineToApplication’ 的节是错误的。如果在 IIS 中没有将虚拟目录配置为应用程序,则可能导致此错误”的解决方法。
- php 在windows下配置虚拟目录的方法
- Ubuntu 17.10 用 apt 搭建 lamp 环境、安装 phpmyadmin、redis 服务+扩展、mysql 扩展、开启错误提示、配置虚拟主机
- 在Win7中IIS配置Asp.Net虚拟目录的方法及错误总结!
- php 在windows下配置虚拟目录的方法介绍
- 程序发布后报图表处理程序配置 [c:\TempImageFiles\] 中的临时目录无效的错误解决方法之一
- 在应用程序级别之外使用注册为 allowDefinition=’MachineToApplication’ 的节是错误的。如果在 IIS 中没有将虚拟目录配置为应用程序,则可能导致此错误”的解决方法
- “在应用程序级别之外使用注册为 allowDefinition=’MachineToApplication’ 的节是错误的。如果在 IIS 中没有将虚拟目录配置为应用程序,则可能导致此错误”的解决方法
- 搭建Windows系统下php开发环境有很多种方式,比如LAMP的配置、php IDE和调试工具的选择等等。根据每个人喜好不同有很多配置方式。这里主要介绍的是利用XAMPP集成安装和配置apache、
- php 在windows下配置虚拟目录的方法介绍
- "在应用程序级别之外使用注册为 allowDefinition='MachineToApplication' 的节是错误的。如果在 IIS 中没有将虚拟目录配置为应用程序,则可能导致此错误"的解决方法
- Windows环境下Apache的安装与虚拟主机, 虚拟目录的配置
- windows下xampp集成环境安装配置方法 、部署bugfree及部署禅道
- Windows7下“/”应用程序中的服务器错误。allowDefinition='MachineToApplication' 的节是错误的。如果在 IIS 中没有将虚拟目录配置为应用程序,则可能导致此错误。
- IIS虚拟目录内的视频文件访问出错:HTTP 错误 404.3 - Not Found 由于扩展配置问题而无法提供您请求的页面。如果该页面是脚本,请添加处理程序。如果应下载文件,请添加 MIME 映射。
- 集成环境配置虚拟目录
- wamp集成环境的虚拟域名配置方法
- “在应用程序级别之外使用注册为 allowDefinition=’MachineToApplication’ 的节是错误的。如果在 IIS 中没有将虚拟目录配置为应用程序,则可能导致此错误”的解决方法