我爱占星网 我爱占星网
首页
编程
java
php
前端
首页 编程 java php 前端

添加site / index.php / city作为codeigniter url路由无法正常工作

I have writing codeigniter URL routes for my site, the route is

$route['index.php/([a-zA-Z0-9---_%])+'] = 'site/index/$1';

when i try to access the link like as below

http://localhost/site/index.php/india

is not working, it redirects to 404 page.

If you have a link

http://localhost/site/index.php/india

You need write this route:

$route['site/index.php/(:any)'] = 'site/index/$1';

近期文章

  • 是否可以在一个php文档中包含多个file()标记
  • PHP SOAP WSDL协议
  • Laravel View包含额外的“<”字符
  • API响应提取方法不称为CI
  • 关于Xampp上的css Laravel-Voyager项目的404
  • 如何在php中使用碳减去两次?
  • 如何将触发器限制在仅在产品发生任何变化时删除woo商店中的瞬态的操作?
  • 需要按选定的条款按顺序显示帖子
  • PHP - 获取谷歌显示的价格
  • 如果数据长度可能超过BLOB大小,如何存储CodeIgniter会话数据?
  • VS Code自动生成php类中的接口方法?
  • 为什么laravel \ Storage :: store方法会导致此错误?
  • 使用Eloquent检索外键的名称
  • 离子订阅返回“错误”,但PHP响应是“成功”
  • 带Guzzle查询问题的Google自定义搜索
  • 如何使用php和mysqli在html页面的数据库中显示用户帐户图片和名称?
  • 停止与模式匹配的wordpress缓存URL,或者如果用户已登录且存在cookie
  • 如何正确配置php - CENTOS 6
  • 无法打开phpmyadmin
  • Android自动滚动新闻栏php

Copyright ©2022 我爱占星 All Rights Reserved.

浙ICP备2022030071号-1

部分图文来自网络,如有侵犯您的版权,请告诉我们删除

友情链接:代码精华