CodeIgniter Forums

Full Version: 404 error from codeigniter when hosted to server (tried every possible conditions)
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4
im getting 404 error when i hosted to server

i checked capital letter at starting.

Please some one help me.
Did you change your base url in the config.php file to point to your domain?
(05-31-2019, 03:18 AM)InsiteFX Wrote: [ -> ]Did you change your base url in the config.php file to point to your domain?

yes i did
Are you trying to use any special routes?

Please show us the code for the controller and view of one such page.
[attachment=1540][attachment=1541][attachment=1542]
(05-31-2019, 04:57 AM)dave friend Wrote: [ -> ]Are you trying to use any special routes?

Please show us the code for the controller and view of one such page.

index is working but login is showing 404 error
(05-31-2019, 05:39 AM)chinna Wrote: [ -> ]
(05-31-2019, 04:57 AM)dave friend Wrote: [ -> ]Are you trying to use any special routes?

Please show us the code for the controller and view of one such page.

index is working but login is showing 404 error

In the welcome() function the last line is

PHP Code:
$this->load->view('loginn"); 

Should "loginn" be "login"? If it should be "login" that may be the source of the 404.

In the future please copy and paste all code into the message editor, then use the PHP button in the toolbar to make it as PHP code. It's less work for everybody in the long run. Thanks.
If the .htaccess file you show is in the website's public folder then you should delete the following code

Code:
<IfModule authz_core_module>
    Require all denied
</IfModule>
<IfModule !authz_core_module>
   Deny from all
</IfModule>

You don't want to deny access to the web server, do you?
(05-31-2019, 08:03 AM)dave friend Wrote: [ -> ]
(05-31-2019, 05:39 AM)chinna Wrote: [ -> ]
(05-31-2019, 04:57 AM)dave friend Wrote: [ -> ]Are you trying to use any special routes?

Please show us the code for the controller and view of one such page.

index is working but login is showing 404 error

In the welcome() function the last line is

PHP Code:
$this->load->view('loginn"); 

Should "loginn" be "login"? If it should be "login" that may be the source of the 404.

In the future please copy and paste all code into the message editor, then use the PHP button in the toolbar to make it as PHP code. It's less work for everybody in the long run. Thanks.
no bro its correct
(05-31-2019, 08:18 AM)dave friend Wrote: [ -> ]If the .htaccess file you show is in the website's public folder then you should delete the following code

Code:
<IfModule authz_core_module>
   Require all denied
</IfModule>
<IfModule !authz_core_module>
  Deny from all
</IfModule>

You don't want to deny access to the web server, do you?

deleted still not working
(05-31-2019, 05:39 AM)chinna Wrote: [ -> ]
(05-31-2019, 04:57 AM)dave friend Wrote: [ -> ]Are you trying to use any special routes?

Please show us the code for the controller and view of one such page.

index is working but login is showing 404 error

First fix the password code... .

https://paragonie.com/blog/2017/12/2018-...-passwords

Second: https://www.codeigniter.com/user_guide/i...ation-rule

Third: Update the php version 5.5 is very old


Back to the problem:
Check if the .htaccess is allowed
Pages: 1 2 3 4