Home >Backend Development >PHP Tutorial >关于rewrite的很简单的应用

关于rewrite的很简单的应用

WBOY
WBOYOriginal
2016-06-13 11:15:22860browse

求一个关于rewrite的很简单的应用
RewriteRule /(\d+)/  /s\.php\?k=$1

这个只能匹配数字,因为\d 
怎么让他匹配所有英文,数字,还有"_"符号


------解决方案--------------------
试试
RewriteRule /(\w+)/  /s\.php\?k=$1
Statement:
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