Jump to content


Help! Works on Local but not on Server (500 internal error)?

codeigniterserver local godaddy error htaccess

  • Please log in to reply
8 replies to this topic

#1 Codefingers

Codefingers

    Newbie

  • Members
  • Pip
  • 2 posts

Posted 01 March 2015 - 04:34 PM

Hey guys, 

 

I have this issue where I cannot update/insert etc, I am able to view the tables, press cancel and what not however I get this error when I try to update/add.

 

I have put the code below along with the error I am getting.

 

I am using GoDaddy Hosting server, I do not have a hta access at the moment.

 

I am able to edit and add etc on local host, so I am not entirely sure how to solve this problem or even find the root of the problem. 

 

Any suggestions would be great!

 

 

 

error.png


<?php  if ( ! defined('BASEPATH')) exit('No direct script access allowed');
   session_start(); 

class Reviews extends CI_Controller {
 
    function __construct()
    {
        parent::__construct();
 
        /* Standard Libraries of codeigniter are required */
        $this->load->database();
        $this->load->helper('url');
        /* ------------------ */ 
 
        $this->load->library('grocery_CRUD');
    }
 
 /*---------------Review Stuff-----------------*/
    public function reviews_data()
    {

    $crud = new grocery_CRUD();
 
    $crud->set_theme('datatables');
    $crud->set_table('******_reviews');
 
    $crud->set_field_upload('Image','assets/uploads/files');
 
    $output = $crud->render();
 
    $this->_example_output($output);    		
    }
		
 
    function _example_output($output = null) 
    {
        $this->load->view('our_template.php',$output);    
    }
/*------------------End-------------------------*/


/*-------------Pages Data CMS-------------------*/
	public function pages_data()
	{
	$this->grocery_crud->set_table('pagedata');
	$this->grocery_crud->set_theme('datatables');
    
        $output = $this->grocery_crud->render();
 
        $this->_example_output2($output);
		
	}
	
	 function _example_output2($output = null) 
    {
       $this->load->view('our_template2.php',$output); 
   }
/*---------------End-------------------------*/	
   
    function logout()
 {
   $this->session->unset_userdata('logged_in');
   session_destroy();
   redirect('home', 'refresh');
 }
	
	
}


 
EDIT: if this helps, it seems that GoDaddy is moving a file or something? Image shown below.
 
error2_1.png

 

 


Edited by Codefingers, 01 March 2015 - 04:42 PM.


#2 Amit Shah

Amit Shah

    grocery CRUD Master

  • Advanced Member
  • PipPipPip
  • 1,192 posts
  • LocationMumbai, India

Posted 02 March 2015 - 12:08 PM

check it on firebug.. check the response generated..

or best .. check in the error log.. that should give you solution on the same.



#3 Codefingers

Codefingers

    Newbie

  • Members
  • Pip
  • 2 posts

Posted 12 March 2015 - 01:17 PM

Hey, sorry for the late reply,

 

This is what the response generates in firebug, 

 

500 internal server error, and the same error I posted in the original post

 

So this is an error on Godaddys site? Or maybe a clash of plugins or something?



#4 Amit Shah

Amit Shah

    grocery CRUD Master

  • Advanced Member
  • PipPipPip
  • 1,192 posts
  • LocationMumbai, India

Posted 16 March 2015 - 01:41 AM

well.. checkout the htaccess settings for godaddy - it have some different configuration for its deployments



#5 j-gun

j-gun

    Member

  • Members
  • PipPip
  • 20 posts

Posted 07 April 2015 - 05:39 AM

i bet the htaccess problems dude.



#6 Higor Câmara Vaz da Costa

Higor Câmara Vaz da Costa

    Newbie

  • Members
  • Pip
  • 6 posts
  • LocationBrasília, Brazil

Posted 02 June 2015 - 07:39 PM

Same here, localhost on Windows/Wamp all work well.

When put on linux only CI works, when try GC examples get 404 Page Not Found



#7 Freddy Sidauruk

Freddy Sidauruk

    Member

  • Members
  • PipPip
  • 10 posts

Posted 29 August 2015 - 02:55 AM

You didn't load model which acsses database ?



#8 blendedbinah

blendedbinah

    Newbie

  • Members
  • Pip
  • 2 posts

Posted 11 July 2017 - 01:44 PM

I got same problem and do you have any idea on how to fix it?

Thanks



#9 Amit Shah

Amit Shah

    grocery CRUD Master

  • Advanced Member
  • PipPipPip
  • 1,192 posts
  • LocationMumbai, India

Posted 13 July 2017 - 04:51 AM

Well did anyone try to check the output in Firebug Console? 

Well am not sure what is being looked up for here but if it is in context with the image scree shared above, there are a certain warning messages being flashed on with the Ajax call response. That is where the issue is and error comes in. If that is the case, there is a simple solution - turn the environment mode from development to production and it should solve your problem / issues.

If there are any other issues, do share in here.. i will try to get the solutions on the same.







Also tagged with one or more of these keywords: codeigniterserver, local, godaddy, error, htaccess

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users