CodeIgniter Forums
Codeigniter to cPanel - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5)
+--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24)
+--- Thread: Codeigniter to cPanel (/showthread.php?tid=63076)



Codeigniter to cPanel - marvinzamoras - 09-23-2015

Hello guys. I badly need your help. I am currently an intern in an NGO. My job is to create a CMS for the organization. I followed a tutorial about creating a CMS. Actually it worked on my localhost. Now I will be moving it to the live server. I already uploaded all necessary files to cPanel. when I tried accessing it via (http://ngoWebsite.com) it showed a 404 error.

Here is my setting of my index.php before uploading it to cPanel:

APPLICATION ENVIRONMENT:

switch (dirname(__FILE__)) {

case 'C:\xampp\htdocs\ngoWebsite':

define('ENVIRONMENT', 'development');
break;
default:
define('ENVIRONMENT', 'production');
break;

ERROR REPORTING:
if (defined('ENVIRONMENT')){
switch (ENVIRONMENT)
{
case 'development':
error_reporting(E_ALL | E_STRICT);
break;
case 'testing':
case 'production':
error_reporting(0);
break;
default:
exit('The application environment is not set correctly.');

}

Here is the structure of my cPanel:
home/ngoWebsite
     >public_html
        >all my files here including index.php

Thanks in advance.


RE: Codeigniter to cPanel - Diederik - 09-23-2015

Does http://ngoWebsite.com/index.php work? If it does then there is something wrong in your .htaccess file, if it still returns the 404 message you have uploaded it to the wrong dir, or the DNS does not point to the same server.