Hi all, i'm new to PHP and im getting a T_String parse error on line 3 of this script : <?php define('IN_PHPBB', true); $phpbb_root_path = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './'; $phpEx = substr(strrchr(__FILE__, '.'), 1); include($phpbb_root_path . 'common.' . $phpEx); // Start session management $user->session_begin(); $auth->acl($user->data); $user->setup(); page_header('clubshop'); $template->set_filenames(array(     'body' => 'clubshop.html', )); make_jumpbox(append_sid("{$phpbb_root_path}viewforum.$phpEx")); page_footer(); ?> I've been looking and looking but i can't see the problem , can anyone help ? Thanks !
I put the code on my server and ran it. I am not getting any syntax errors. (I am getting obvious errors on the include, but those wouldnt show if there were syntax errrors) Are you sure the error is coming from this file and not an included file?
thanks for replying, when i goto the file in my browser this is the error i get : Parse error: syntax error, unexpected T_STRING in /home/hjscc/public_html/clubshop.php on line 3 I cant see anything wrong so it may be an included file as you say , would it be the root path ?
Emm not sure, what is the . for ? $phpEx = substr(strrchr(__FILE__, '.'), 1); Maybe try it this way $phpEx = substr(strrchr(__FILE__) . '.', 1);
tried changing it anyway and it still comes up with the same error, i have put clubshop.php in the root folder where my phpbb is.
As xrvel said,you should try to put your clubshop.php here. Your code what you paster is right.The error is "Parse error: syntax error, unexpected T_STRING in /home/hjscc/public_html/clubshop.php on line 3".