php Zend / MVC without mod_rewrite

前端 未结 5 1603
攒了一身酷
攒了一身酷 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 09:18

    mod_rewrite is almost essential in today's hosting environment..but unfortunately not everyone got the message.

    Lots of the large php programs (I'm thinking magento, but most can cope) have a pretty-url fall back mode for when mod_rewrite isn't available.

    URLs end up looking like www.site.com/index.php?load-this-page

    They must be running some magic to grab the variable name from the $_GET variable and using it as the selector for what module/feature to execute.

    In a related note, I've seen lots of messed up URLs in the new facebook site where it's using the #. So links look like www.new.facebook.com/home.php#/inbox/ Clearly we're not meant to see that but it suggests that they're probably parsing the $_SERVER['REQUEST_URI'] variable.

提交回复
热议问题