dpp34603 2014-11-12 12:54
浏览 33
已采纳

每页都有codeigniter'找不到404页面'

I used this .htaccess file on my localhost:

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule .* index.php/$0 [PT,L] 

But when I uploaded my site to the ftp, it suddenly doesn't work. I set the base_url. Mod rewrite is enabled. What else can be the problem. My knowledge is very limited, I was already happy, that I programming part, but this server stuff is over my head. But I'm willing to learn it, so if you recommend a place to start, I'm open to that.

So right now only a formatted page comes in, with basic css settings and the 404 message. It's weird, that this message can be created in a form like that, so it means it's not a technical problem, but a settings problem. I googled around, tried more .htaccess files, but nothing works. Thanks for your help!

  • 写回答

2条回答 默认 最新

  • duanmeng3126 2014-11-13 11:20
    关注

    This is silly. The controllers must be named starting with a big case letter. So the only problem was, that I named my default controller as welcome.php instead of Welcome.php. It was hard to figure out, because it worked on localhost. So this had nothing to do with .htaccess at all. May be valuable to others, so they don't make the same mistake.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥50 如何用脚本实现输入法的热键设置
  • ¥20 我想使用一些网络协议或者部分协议也行,主要想实现类似于traceroute的一定步长内的路由拓扑功能
  • ¥30 深度学习,前后端连接
  • ¥15 孟德尔随机化结果不一致
  • ¥15 apm2.8飞控罗盘bad health,加速度计校准失败
  • ¥15 求解O-S方程的特征值问题给出边界层布拉休斯平行流的中性曲线
  • ¥15 谁有desed数据集呀
  • ¥20 手写数字识别运行c仿真时,程序报错错误代码sim211-100
  • ¥15 关于#hadoop#的问题
  • ¥15 (标签-Python|关键词-socket)