我试图在内置的Android浏览器中打开我的PHP脚本,但我只看到我的代码,作为文本,PHP没有运行.这是为什么 ?
如何在Android设备上运行PHP?有没有办法在Android设备上设置PHP和Web服务器?
我是 CodeIgniter、一般框架的完全初学者,我尝试了 Laravel 和 CakePHP,但两者安装起来都非常复杂(对我来说),所以现在我已经下载了 CI,除了这个访问被拒绝错误之外,它看起来非常简单。
该错误是默认的 Firefox 403(访问被拒绝)错误。它说:
You don't have permission to access the requested object. It's either read-protected or not readable by the server.
当我去时会发生这种情况localhost/codeigniter/application
我的基本网址:http://localhost/codeigniter/application. 我不知道为什么我会这样设置,但这似乎是合乎逻辑的。
更新:在我编辑 htaccess 文件使其看起来像这样:` RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.PHP/$1 [L]
Run Code Online (Sandbox Code Playgroud)
,它给了我另一个 403 错误(这不是默认的 Firefox 错误),它只是说“目录访问被禁止”。