[英]Routing my URL in CodeIgniter
I tried remapping my URL, but without any success. 我尝试重新映射我的URL,但没有成功。 Here is my URL:
这是我的网址:
localhost:8888/nordia/site/categorie/1/transportwagon
What I'm trying to do is remove the "site" part from URL and keep it like: 我想做的是从URL中删除“网站”部分,并保持如下所示:
localhost:8888/nordia/categorie/1/transportwagon
I tried mapping it like: 我试着像这样映射它:
$route['site/categorie'] = "categorie";
But it is not working. 但这是行不通的。 What am I doing wrong here?
我在这里做错了什么?
它应该是
$route['categorie/(:num)/(:any)'] = "site/categorie/$1/$2";
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.