-
AuthorPosts
-
November 8, 2009 at 12:41 pm #145860
Dohh! I have been editing in the mod_footer php code, and somehow I have missed a tag or made an unclosed sentence. Let me tell you, I am a php newbie. I promise never to do this again.
The problem causes my site to go white screen with this msg:
Parse error: syntax error, unexpected T_STRING in /hsphere/local/home/blikfanger/blikfanger.dk/modules/mod_footer/mod_footer.php on line 14
The code in mod_footer is this:<?php
/**
* @version $Id: mod_footer.php 10381 2008-06-01 03:35:53Z pasamio $
* @package Joomla
* @copyright Copyright (C) 2005 – 2008 Open Source Matters. All rights reserved.
* @license GNU/GPL, see LICENSE.php
* Joomla! is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/no direct access defined(‘_JEXEC’) or die(‘Restricted access’);
global $mainframe;
$date =& JFactory::getDate();
$cur_year = $date->toFormat(‘%Y’);
$csite_name = $mainframe->getCfg(‘sitename’);if (JString::strpos(JText :: _(‘FOOTER_LINE1’), ‘%date%’)) {
$line1 = ereg_replace(‘%date%’, $cur_year, JText :: _(‘FOOTER_LINE1’));
} else {
$line1 = JText :: _(‘FOOTER_LINE1’);
}if (JString::strpos($line1, ‘%sitename%’)) {
$lineone = ereg_replace(‘%sitename%’, $csite_name, $line1);
} else {
$lineone = $line1;
}require(JModuleHelper::getLayoutPath(‘mod_footer’));
Anonymous ModeratorJA Developer
- Join date:
- September 2014
- Posts:
- 9914
- Downloads:
- 207
- Uploads:
- 152
- Thanks:
- 1789
- Thanked:
- 2008 times in 1700 posts
November 12, 2009 at 4:17 pm #323419Please change to:
[PHP]
<?php
/**
* @version $Id: mod_footer.php 10381 2008-06-01 03:35:53Z pasamio $
* @package Joomla
* @copyright Copyright (C) 2005 – 2008 Open Source Matters. All rights reserved.
* @license GNU/GPL, see LICENSE.php
* Joomla! is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*///no direct access
defined(‘_JEXEC’) or die(‘Restricted access’);
global $mainframe;
$date =& JFactory::getDate();
$cur_year = $date->toFormat(‘%Y’);
$csite_name = $mainframe->getCfg(‘sitename’);if (JString::strpos(JText :: _(‘FOOTER_LINE1’), ‘%date%’)) {
$line1 = ereg_replace(‘%date%’, $cur_year, JText :: _(‘FOOTER_LINE1’));
} else {
$line1 = JText :: _(‘FOOTER_LINE1’);
}if (JString::strpos($line1, ‘%sitename%’)) {
$lineone = ereg_replace(‘%sitename%’, $csite_name, $line1);
} else {
$lineone = $line1;
}require(JModuleHelper::getLayoutPath(‘mod_footer’) );
[/PHP] -
AuthorPosts
This topic contains 2 replies, has 2 voices, and was last updated by Anonymous 15 years, 1 month ago.
We moved to new unified forum. Please post all new support queries in our New Forum