Helllo everyone。我desperatly试图让codeigniter运行在网络服务器上。 apache mod_rewrite已启用,并且我尝试了几乎所有与Internet上发现的相关的内容,但都没有成功。Codeigniter:从本地主机到网络服务器
在Web服务器上的目录是
在cgi-bin文件夹已经已经存在。我读过的帖子说,cgi-bin文件夹自it is hardly used these days以来无关紧要。 但这是第一个问题:我也支持这个吗?我应该使用哪个.htaccess文件?为什么.htaccess文件放在那里?
他们都不似乎工作: 我试了几个设置,我结束了以下版本两个.htaccess文件:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /test94252.test-account.com
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /test94252.test-account.com/index.htm [L]
</IfModule>
我的目标很简单,如果我叫域http://website.com/那/网站/应用程序/ views/index.php被调用。 这个.htaccess文件有什么问题?
编辑:在我的本地机器上,我通过http://localhost/website/Controller/Function调用该index.php文件。
请注意:为了测试的缘故,我把index.htm放到/ website /中来检查重定向是否完成,但是它不起作用。
我期待着您的回音。
嗨,是位于public_html文件夹中的文件夹“网站”? –