#
#以下是网站伪静态正则
#
RewriteEngine On
RewriteRule ^index.html$ index.php
RewriteRule ^about.html$ about.php
RewriteRule ^about_([0-9]+).html$ about.php?id=$1
RewriteRule ^contact.html$ contact.php
RewriteRule ^service.html$ service.php
RewriteRule ^case.html$ case.php
RewriteRule ^case_([0-9]+).html$ case.php?fid=$1
RewriteRule ^case_show_([0-9]+).html$ case_show.php?id=$1
RewriteRule ^wenda.html$ wenda.php
RewriteRule ^wenda_show_([0-9]+).html$ wenda_show.php?id=$1
RewriteRule ^interact.html$ interact.php
RewriteRule ^interact_show_([0-9]+).html$ interact_show.php?id=$1
RewriteRule ^news.html$ news.php
RewriteRule ^news_([0-9]+).html$ news.php?fid=$1
RewriteRule ^news_show_([0-9]+).html$ news_show.php?id=$1
RewriteRule ^news_page([[0-9]+).html$ news.php?page=$1
RewriteRule ^news_fid([[0-9]+)_page([[0-9]+).html$ news.php?fid=$1&page=$2
RewriteRule ^wenti_([0-9]+).html$ wenti.php?fid=$1
RewriteRule ^wenti_show_([0-9]+).html$ wenti_show.php?id=$1
RewriteRule ^wenti_fid([[0-9]+)_page([[0-9]+).html$ wenti.php?fid=$1&page=$2
RewriteRule ^zhuanjia_([0-9]+).html$ zhuanjia.php?fid=$1
RewriteRule ^zhuanjia_show_([0-9]+).html$ zhuanjia_show.php?id=$1
RewriteRule ^product.html$ product.php
RewriteRule ^product_([0-9]+).html$ product.php?fid=$1
RewriteRule ^product_show_([0-9]+).html$ product_show.php?id=$1
RewriteRule ^product_page([[0-9]+).html$ product.php?page=$1
RewriteRule ^service_page([[0-9]+).html$ service.php?page=$1
RewriteRule ^interact_page([[0-9]+).html$ interact.php?page=$1
RewriteRule ^wenda_page([[0-9]+).html$ wenda.php?page=$1
RewriteRule ^zhuanjia_fid([[0-9]+)_page([[0-9]+).html$ zhuanjia.php?fid=$1&page=$2
RewriteRule ^save_action_([a-z]+).html$ save.php?action=$1

php .htaccess 伪静态的更多相关文章

  1. .htaccess伪静态(URL重写)绑定域名到子目录实现子站点

    Apache主机一般支持.htaccess伪静态,即可以实现绑定域名到子目录.一个空间多个站点. 应用举例:绑定htaccess.800m.net到htaccess目录 根目录下.htaccess内容 ...

  2. nginx上支持.htaccess伪静态的配置实例

    本文介绍下,在nginx上配置.htaccess伪静态的方法,有需要的朋友参考下吧. 在apache上.htaccess转向,只要apache编译的时候指明支持rewrite模块即可. 但是换到ngi ...

  3. apache上.htaccess转向nginx上配置.htaccess伪静态规则

    nginx上配置.htaccess伪静态规则 在apache上.htaccess转向,只要apache编译的时候指明支持rewrite模块即可. 但是换到nginx上方法会有不同,有人说把.htacc ...

  4. Linux启动Apache支持.htaccess伪静态文件方法

    第一.编辑httpd.conf文件 A - 在etc/httpd/conf/目录下的httpd.conf 文件,找到: LoadModule rewrite_module modules/mod_re ...

  5. nginx上如何支持.htaccess伪静态转向

    我们知道在apache上有一个常用的功能.htaccess转向,只要apache编译的时候指明支持rewrite模块就可以了. 但是换到nginx上方法会有一点不一样,网上很多人说把.htaccess ...

  6. linux网站配置文件.htaccess伪静态转换到IIS web.config中

    linux下的php网站放到Windows服务器IIS下.htaccess文件伪静态规则转换.   此办法只适合于linux下的php网站放到Windows服务器IIS下,网站除了主页面正常以外子页面 ...

  7. 如何在windows下Apache环境开启htaccess伪静态功能

     以下文章来自于网络,只做学习用 很多国人习惯用windows服务器或者在windows系统下调试PHP程序,在调试货使用的时候就遇到开启伪静态的各种问题,今天在网络上搜集了一些开启伪静态需要注意 ...

  8. htaccess 伪静态的规则

    利用htaccess文件可以很好的进行站点伪静态,并且形成的目标地址与真正的静态页面几乎一模一样,如abc.html等,伪静态可以非常好的结合SEO来提高站点的排名,并且也能给人一种稳定的印象. 由于 ...

  9. Apache环境.htaccess伪静态301跳转(www与不带www)

    一般而言,我们使用的301跳转就是WWW与不带WWW域名之间的跳转,用行话说就是权重要归一.对于我们使用Apache环境的来说其实相对nginx比较简单,因为只需要我们在网站根目录有.htaccess ...

  10. apache .htaccess 伪静态重定向,防盗链 限制下载...

    301全站跳转 RewriteEngine OnRewriteCond %{HTTP_HOST} ^www\.old\.net$ [NC]RewriteRule ^(.*)$ http://www.n ...

随机推荐

  1. SAP Tax Service可以取代TAXBRA / RVABRA吗?(翻译) 跨国贸易云税务解决方案

    这篇文章的内容基于Fausto Motter  的一篇文章,他在SAP社区用葡萄牙语写了一篇文章,讨论如何用云解决方案取代巴西税收计算.我翻译了他的部分文章,添加并修改了一些内容,目标是帮助全球的SA ...

  2. laravel5.8笔记二:部署

    部署项目之前需要知道的几件事 1.有几个模块(admin,index,wap,api) 2.有几个数据库(mysql1,mysql2,mysql3) 3.有那些缓存(redis1,redis2,red ...

  3. 理解面向过程(OPP)、面向对象(OOP)、面向切面(AOP)

    概念 面向过程编程OPP:Procedure Oriented Programming,是一种以事物为中心的编程思想.主要关注“怎么做”,即完成任务的具体细节. 面向对象编程OOP:Object Or ...

  4. Linux下查看设设置时间date命令

    查看时间 # date "+%Y_%m_%d  %H-%M-%S" 设置时间 #date -s "2018-05-17 09:51:50" //写入到硬件时钟 ...

  5. phpadmin dvwa sqli-labs xsser.me

    下载phpadmin,安装后网站根目录 phpStudy\PHPTutorial\WWW 将下载的dvwa文件夹放到该目录下,修改config/config.inc.php文件中的mysql连接信息. ...

  6. Python中的test测试

    不知道怎么回事,打开的工程中出现了pytest,难道是检测到了我的命名中有test吗? 参考博文:https://blog.csdn.net/weixin_41605937/article/detai ...

  7. threding模块的其他用法

    import threading import time def func(n): time.sleep(0.5) n += 1 print(n, threading.current_thread() ...

  8. Radar Installation---(贪心)

    Radar Installation Time Limit: 1000MS   Memory Limit: 10000K Total Submissions: 115873   Accepted: 2 ...

  9. c++课设

    #include <stdio.h>#include <time.h>#include <math.h>#define C 60000;struct Student ...

  10. day18 十八、random、shutil、shevle、logging

    一.random 模块:随机数 1. import random # .[,]整数 random randint(,) print(random.randint(, )) # 随机产生[,]中的一个数 ...