Home > Backend Development > PHP Tutorial > 请问一个简单的url重写有关问题

请问一个简单的url重写有关问题

WBOY
Release: 2016-06-13 12:10:45
Original
902 people have browsed it

请教一个简单的url重写问题
请教怎么将 zonggang.php?shuhao=130
 重写成  read/130

用 RewriteRule 重写

------解决思路----------------------
RewriteRule ^/?read/([0-9]+) zonggang.php?shuhao=$1
------解决思路----------------------
RewriteEngine on

RewriteRule read/(\d+) zonggang.php?shuhao=$1 [NC]
------解决思路----------------------

<br />RewriteEngine On<br />RewriteRule ^read\/([0-9]+)$ zonggang.php?shuhao=$1 [NC] [NC]<br />
Copy after login

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template