apache,R,P,url重写,伪静态,反向代理
2013-12-23 17:27
323 查看
需求:
1,浏览器地址栏中URL不变
2,伪静态重写生效
=====================
<VirtualHost *>
ServerName xinwen.888.com.cn
ServerAlias www.xinwen.888.com.cn
DocumentRoot /data/xinwen
CustomLog "|/usr/local/cronolog/sbin/cronolog /usr/local/apache2/logs/xinwen_access%Y%m%d.log" combined env=!NOFILES
ErrorDocument 404 /404.html
<Directory "/data/xinwen/">
Options FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
Deny from 111.111.0.
Deny from 111.111.4.
</Directory>
<IfModule mod_weblogic.c>
WebLogicHost 127.0.0.1
WebLogicPort 8080
MatchExpression *.jsp
MatchExpression */rlr*
MatchExpression */dwr/*
WLTempDir /home/userputong/wltemp
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule /xinwen_(.*).html$ /rlrxinwenlist?classid=$1 [R,P]
RewriteRule /showxinwen(.*).html /rlrxinwendetail?id=$1 [R,P]
</IfModule>
</VirtualHost>
1,浏览器地址栏中URL不变
2,伪静态重写生效
=====================
<VirtualHost *>
ServerName xinwen.888.com.cn
ServerAlias www.xinwen.888.com.cn
DocumentRoot /data/xinwen
CustomLog "|/usr/local/cronolog/sbin/cronolog /usr/local/apache2/logs/xinwen_access%Y%m%d.log" combined env=!NOFILES
ErrorDocument 404 /404.html
<Directory "/data/xinwen/">
Options FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
Deny from 111.111.0.
Deny from 111.111.4.
</Directory>
<IfModule mod_weblogic.c>
WebLogicHost 127.0.0.1
WebLogicPort 8080
MatchExpression *.jsp
MatchExpression */rlr*
MatchExpression */dwr/*
WLTempDir /home/userputong/wltemp
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule /xinwen_(.*).html$ /rlrxinwenlist?classid=$1 [R,P]
RewriteRule /showxinwen(.*).html /rlrxinwendetail?id=$1 [R,P]
</IfModule>
</VirtualHost>
相关文章推荐
- linux下的squid代理
- squid+nginx+varnish资料整理
- nginx做反向代理负载均衡 后端服务器如何获取用户的IP
- 读写分离 URL重写 页面缓存 Nginx 反向代理
- Nginx反向代理设置
- nginx反向代理配置
- python 脚本统计squid日志中的IP访问数和URL访问数量
- 自建CDN技术选型: squid varnish nginx
- squid中的X-Cache和X-Cache-Lookup的意义
- 对Squid使用的一些总结
- Squid故障与解决方法汇总
- windows环境下用squid代理https(ssl)的方法
- Squid服务的安装和配置
- 记录一下,如何配置nodejs nginx的反向代理
- nginx 在windows平台上对asp.net做反向代理
- squid反向代理及缓存示例
- squid缓存代理服务基本配置
- ubuntu下设置代理服务器 Squid
- nginx反向代理及缓存
- squid反向代理作为web前端内容缓存器及局域网内客户机通过代理服务器上网