Why am I getting a 403 Forbidden error using codeigniter locally?
As mentioned in the comments you shouldn't be trying to directly access the .php
file your controller resides in. Direct script access isn't allow which is why you are getting the 403. You need to send request through your index.php
. So rather than using this URL
localhost/intranet/CodeIgniter_2.1.4/application/controllers/welcome.php
You need to use
localhost/intranet/CodeIgniter_2.1.4/welcome //Use this if your .htaccess removes index.php
localhost/intranet/CodeIgniter_2.1.4/index.php/welcome
Or to access your login form
localhost/intranet/CodeIgniter_2.1.4/welcome/login_form //Use this if your .htaccess removes index.php
localhost/intranet/CodeIgniter_2.1.4/index.php/welcome/login_form
If there are htaccess files change denied to granted or just remove them entirely