php Zend / MVC without mod_rewrite

前端 未结 5 1527
攒了一身酷
攒了一身酷 2021-01-22 08:19

I\'ve seen it mentioned in many blogs around the net, but I believe it shoud be discussed here. What can we do when we have an MVC framework (I am interested in ZEND) in PHP but

5条回答
  •  被撕碎了的回忆
    2021-01-22 08:53

    If you can find a non-mod_rewrite way to redirect all requests to index.php (or wherever your init script is), you can, as mentioned above, use 'REQUEST_URI' to grab the portion of the address after the domain and then parse it as you like and make the request do what you want it to. This is how Wordpress does it (granted, with mod_rewrite). As long as you can redirect requests to your index page while retaining the same URI, you can do what you need to to process the request.

提交回复
热议问题