开发者

Do PHP scripts work if htaccess url rewrite is implemented?

If I use mod-rewrite to change a ur开发者_运维问答l like this:

http://www.mysite.com/page.php?title=my-name-is-john

to

http://www.mysite.com/page/my-name-is-john

and if the page.php file contains a script that relies on parameters passed through the url like:

$_GET['title'];

Then will that script still work after the mod-rewrite has been implemented?


Yes, mod rewrite is transparent to the php scripts. So for the script it seems was just requested with the old url.


Yes. Your script will still work.

(ModRewrite is essentially transparent to PHP/and other CGIs you run.)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜