PHP - How to add a pages title to the URL? And how to create a clean url using PHP

后端 未结 3 579
刺人心
刺人心 2021-01-15 09:39

I was wondering how can I create clean urls using PHP. Do I do this all in PHP or do I need to use mod_rewrite in some way? Can someone explain this to me in laymans terms?<

3条回答
  •  独厮守ぢ
    2021-01-15 09:54

    You have to use a rewrite to direct all requests to an existing php file, otherwise you get all 404 not found errors because you are trying to get a page that simply is not there.

    Unless you rewrite your 404 page to handle all requests and you definitely don´t want to go there...

提交回复
热议问题