Hello all,
I have recently moved my site to hostgator and now i am getting this error
Parse error: syntax error, unexpected T_VARIABLE in /home/jiglow/public_html/mysite.net/index.php on line 26
I have lost count on all the forums and websites i have visited trying to fing the answer. Most of the answers i find are about the semi colon missing but mine is there. Here is the code

<?php
/*
|---------------------------------------------------------------
| PHP ERROR REPORTING LEVEL
|---------------------------------------------------------------
|
| By default CI runs with error reporting set to ALL.  For security
| reasons you are encouraged to change this when your site goes live.
| For more info visit:  http://www.php.net/error_reporting
|
*/
	error_reporting(0)

/*
|---------------------------------------------------------------
| SYSTEM FOLDER NAME
|---------------------------------------------------------------
|
| This variable must contain the name of your "system" folder.
| Include the path if the folder is not in the same  directory
| as this file.
|
| NO TRAILING SLASH!
|
*/
	$system_folder = "system";

/*
|---------------------------------------------------------------
| APPLICATION FOLDER NAME
|---------------------------------------------------------------
|
| If you want this front controller to use a different "application"
| folder then the default one you can set its name here. The folder 
| can also be renamed or relocated anywhere on your server.
| For more info please see the user guide:
| http://codeigniter.com/user_guide/general/managing_apps.html
|
|
| NO TRAILING SLASH!
|
*/
	$application_folder = "application";

/*
|===============================================================
| END OF USER CONFIGURABLE SETTINGS
|===============================================================
*/


/*
|---------------------------------------------------------------
| SET THE SERVER PATH
|---------------------------------------------------------------
|
| Let's attempt to determine the full-server path to the "system"
| folder in order to reduce the possibility of path problems.
| Note: We only attempt this if the user hasn't specified a 
| full server path.
|
*/
if (strpos($system_folder, '/') === FALSE)
{
	if (function_exists('realpath') AND @realpath(dirname(__FILE__)) !== FALSE)
	{
		$system_folder = realpath(dirname(__FILE__)).'/'.$system_folder;
	}
}
else
{
	// Swap directory separators to Unix style for consistency
	$system_folder = str_replace("\\", "/", $system_folder); 
}

/*
|---------------------------------------------------------------
| DEFINE APPLICATION CONSTANTS
|---------------------------------------------------------------
|
| EXT		- The file extension.  Typically ".php"
| FCPATH	- The full server path to THIS file
| SELF		- The name of THIS file (typically "index.php")
| BASEPATH	- The full server path to the "system" folder
| APPPATH	- The full server path to the "application" folder
|
*/
define('EXT', '.'.pathinfo(__FILE__, PATHINFO_EXTENSION));
define('FCPATH', __FILE__);
define('SELF', pathinfo(__FILE__, PATHINFO_BASENAME));
define('BASEPATH', $system_folder.'/');

if (is_dir($application_folder))
{
	define('APPPATH', $application_folder.'/');
}
else
{
	if ($application_folder == '')
	{
		$application_folder = 'application';
	}

define('APPPATH', BASEPATH.$application_folder.'/');
}

/*
|---------------------------------------------------------------
| LOAD THE FRONT CONTROLLER
|---------------------------------------------------------------
|
| And away we go...
|
*/
require_once BASEPATH.'codeigniter/CodeIgniter'.EXT;

/* End of file index.php */
/* Location: ./index.php */

Line 26 is

$system_folder = "system"; 

If i remove that line then it simply moves on to the next syntex error.
I dont have much of a clue about php so any help would greatly be appreciated.

Thanks in advance

    You left out the terminal semi-colon on the error_reporting() line.

      thanks for the reply NogDog i removed that on purpose because it wont the show the error on the page when the semi colon is there. I simply get a blank white page when the semi colon is there.

      Thanks anyway

        Dam. I fixed it. Nothing to do with the index.php file. I changed this

        error_reporting(0)
        to this
        error_reporting(1);

        and it told me it was another file causing the problem decoder.php
        i looke at my script instructions and i should have uploaded the decoder.php file in binary mode which i have now done.

        fooya

          fooya;11025611 wrote:

          i looke at my script instructions and i should have uploaded the decoder.php file in binary mode which i have now done.

          fooya

          Glad to hear it!

          Please consider using the "thread tools" drop down at the top of your first post to mark this thread as "Resolved". Thanks, and welcome to PHPBuilder!

            Write a Reply...