Upgrade to Joomla 2.5.7 - mod_title.php error
Moderator: ooffick
Forum rules
Please use the official Bug Tracker to report a bug: https://issues.joomla.org
Please use the official Bug Tracker to report a bug: https://issues.joomla.org
-
- Joomla! Fledgling
- Posts: 3
- Joined: Sat Sep 15, 2012 9:45 am
Upgrade to Joomla 2.5.7 - mod_title.php error
Hi All!
I'am using the Glossary Component Glossary28J2.
I upgraded from Joomla 2.5.6 to 2.5.7 which leads to the following error message when switching to the glossary menu in the backend:
Notice: Undefined property: JAdministrator::$JComponentTitle in /home/www/web223/html/Joomla/administrator/modules/mod_title/mod_title.php on line 13
The code says the following at line 13:
// Get the component title div
$title = JFactory::getApplication()->JComponentTitle;
With 2.5.6 this message never appeared.
I'am not a php professional, so please could anyone of you help out here?
Thanks in advance!
I'am using the Glossary Component Glossary28J2.
I upgraded from Joomla 2.5.6 to 2.5.7 which leads to the following error message when switching to the glossary menu in the backend:
Notice: Undefined property: JAdministrator::$JComponentTitle in /home/www/web223/html/Joomla/administrator/modules/mod_title/mod_title.php on line 13
The code says the following at line 13:
// Get the component title div
$title = JFactory::getApplication()->JComponentTitle;
With 2.5.6 this message never appeared.
I'am not a php professional, so please could anyone of you help out here?
Thanks in advance!
-
- Joomla! Fledgling
- Posts: 1
- Joined: Mon Sep 17, 2012 3:44 pm
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
Seems to be a typical 2.5.7 bug - There is a quick workaround that works for me.
Change the line 13:
$title = JFactory::getApplication()->JComponentTitle;
into the following:
$title = JFactory::getApplication()->get('JComponentTitle');
Good luck.
Change the line 13:
$title = JFactory::getApplication()->JComponentTitle;
into the following:
$title = JFactory::getApplication()->get('JComponentTitle');
Good luck.
- humvee
- Joomla! Master
- Posts: 14704
- Joined: Wed Aug 17, 2005 10:27 pm
- Location: Kent, England
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
If this a bug that you are certain exists then you should place a notification to the 2.5. Bug Forum / 2.5. Bug Tracker with full details. If it has already been reported please quote the Bug Tracker reference so that people can follow official developments on it.HarryH wrote:Seems to be a typical 2.5.7 bug - There is a quick workaround that works for me.
Change the line 13:
$title = JFactory::getApplication()->JComponentTitle;
into the following:
$title = JFactory::getApplication()->get('JComponentTitle');
Good luck.
As it would seem to be a limited number of instances that are occurring then it is less likely to be a bug but a server/installation configuration issue and editing the core files of Joomla with anything other than an approved temporary fix notice issued by the developers is a dangerous path to follow, particularly for an inexperienced/non-developer user and is not recommended.
-
- Joomla! Fledgling
- Posts: 1
- Joined: Thu Sep 20, 2012 10:37 am
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
Exact same error here, running a Linux debian server with Nginx v1.2.3, MySQL 5.1.58, and PHP 5.3.15
Updated using the 2.5.6 to 2.5.7 package from the extension manager
HarryH's fix worked fine, thanks for that
Updated using the 2.5.6 to 2.5.7 package from the extension manager
HarryH's fix worked fine, thanks for that
-
- Joomla! Fledgling
- Posts: 3
- Joined: Sat Sep 15, 2012 9:45 am
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
i agree with bosit's feedback. worked for me too! thanks harryh!
just checked that this glossary component is not working for multilanguage sites.
is there a way to get an english glossary for the EN website- and a german glossary for the DE website version?
so far, it seems only the SEO Glossary component supports that, but its a commercial version.
any known workarounds?
just checked that this glossary component is not working for multilanguage sites.
is there a way to get an english glossary for the EN website- and a german glossary for the DE website version?
so far, it seems only the SEO Glossary component supports that, but its a commercial version.
any known workarounds?
- LowNotesB
- Joomla! Apprentice
- Posts: 35
- Joined: Sun Feb 18, 2007 12:20 am
- Location: on top of the mountain
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
I'm getting the same error when I try to run extplorer from the backend.
Notice: Undefined property: JAdministrator::$JComponentTitle in /home/xxxxxx/public_html/administrator/modules/mod_title/mod_title.php on line 13
the suggested fix above took away the error message, but the component still fails to load fully and then goes into some kind of loading loop that doesn't stop.
Notice: Undefined property: JAdministrator::$JComponentTitle in /home/xxxxxx/public_html/administrator/modules/mod_title/mod_title.php on line 13
the suggested fix above took away the error message, but the component still fails to load fully and then goes into some kind of loading loop that doesn't stop.
-
- Joomla! Fledgling
- Posts: 1
- Joined: Tue Oct 02, 2012 10:05 am
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
I've the same issue, I'm going to implement your solution, thanks you
It happened when I installed the hello_world joomla development component on the version 2.5.7 of joomla.
I've a cloud site hosting on rackspace.
It happened when I installed the hello_world joomla development component on the version 2.5.7 of joomla.
I've a cloud site hosting on rackspace.
- Klementz
- Joomla! Explorer
- Posts: 400
- Joined: Sun Aug 28, 2005 2:55 pm
- Location: Barrie, Ontario CANADA
- Contact:
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
I am also experiencing the same error with eXtplorer:
Notice: Undefined property: JAdministrator::$JComponentTitle in /[path]/administrator/modules/mod_title/mod_title.php on line 13
It is not a server configuration issue, because I have another site on the same server with the same .htaccess settings and the same firewall configuration settings and the component works fine there.
eXtplorer is the only component that I am having this problem with.
Notice: Undefined property: JAdministrator::$JComponentTitle in /[path]/administrator/modules/mod_title/mod_title.php on line 13
It is not a server configuration issue, because I have another site on the same server with the same .htaccess settings and the same firewall configuration settings and the component works fine there.
eXtplorer is the only component that I am having this problem with.
http://www.jdanielclements.com (Personal photography site)
http://www.coinzoo.net (World coin collection with animals)
http://www.coinzoo.net (World coin collection with animals)
- Webdongle
- Joomla! Master
- Posts: 44070
- Joined: Sat Apr 05, 2008 9:58 pm
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
I suspect that it is deprecated(or badly written) code in the 3rd party extension that triggers the error.
It looks like the Joomla file is written to prevent the code(of 3rd party extensions) using unsanitised database requests. If that is the case then editing the Joomla file could leave your site open to sql injection.
I have raised the issue on the bugsquad mailing list. And hopefully one of the Joomla developers will look at it soon.
Addendum
The Joomla devs say
It looks like the Joomla file is written to prevent the code(of 3rd party extensions) using unsanitised database requests. If that is the case then editing the Joomla file could leave your site open to sql injection.
I have raised the issue on the bugsquad mailing list. And hopefully one of the Joomla developers will look at it soon.
Addendum
The Joomla devs say
JApplication no longer extends JObject which had the get method. So, the code is right
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"When I'm right no one remembers but when I'm wrong no one forgets".
https://www.weblinksonline.co.uk/updating-joomla.html
"When I'm right no one remembers but when I'm wrong no one forgets".
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
A proper fix would be for us to check if JComponentTitle is set before storing it in that variable, and if it isn't, then making the variable an empty string. So, something like this should work:
That variable is only set to the application via JToolbarHelper::title() or the developer explicitly setting that value. An advantage to the old way was that it would mask the error of the JComponentTitle variable not being set by automatically returning the empty string.
As far as any potential security issues with mod_title, since it should only be set by the helper method to get the proper rendering, unless the request data is being explicitly used by a developer without proper sanitization first (meaning using JInput or JRequest), then and only then would there exist a chance at any unwanted activity on your site while trying to set the title to display in the page. Typical use of the helper method doesn't use the request data at all; the most complicated use in the core code is using data already retrieved from the database in if conditionals to set a proper string, otherwise, the title is a simple language key. See this example from the 2.5 code base (which is the same in 3.0) - https://github.com/joomla/joomla-cms/bl ... ml.php#L67
Code: Select all
if (isset(JFactory::getApplication()->JComponentTitle))
{
$title = JFactory::getApplication()->JComponentTitle;
}
else
{
$title = '';
}
As far as any potential security issues with mod_title, since it should only be set by the helper method to get the proper rendering, unless the request data is being explicitly used by a developer without proper sanitization first (meaning using JInput or JRequest), then and only then would there exist a chance at any unwanted activity on your site while trying to set the title to display in the page. Typical use of the helper method doesn't use the request data at all; the most complicated use in the core code is using data already retrieved from the database in if conditionals to set a proper string, otherwise, the title is a simple language key. See this example from the 2.5 code base (which is the same in 3.0) - https://github.com/joomla/joomla-cms/bl ... ml.php#L67
- Webdongle
- Joomla! Master
- Posts: 44070
- Joined: Sat Apr 05, 2008 9:58 pm
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
Where would that fix be placed ?mbabker wrote:A proper fix would be for us to check if JComponentTitle is set before storing it in that variable, and if it isn't, then making the variable an empty string. So, something like this should work:...Code: Select all
if (isset(JFactory::getApplication()->JComponentTitle)) { $title = JFactory::getApplication()->JComponentTitle; } else { $title = ''; }
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"When I'm right no one remembers but when I'm wrong no one forgets".
https://www.weblinksonline.co.uk/updating-joomla.html
"When I'm right no one remembers but when I'm wrong no one forgets".
- Klementz
- Joomla! Explorer
- Posts: 400
- Joined: Sun Aug 28, 2005 2:55 pm
- Location: Barrie, Ontario CANADA
- Contact:
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
/administrator/modules/mod_title/mod_title.phpWebdongle wrote:Where would that fix be placed ?mbabker wrote:A proper fix would be for us to check if JComponentTitle is set before storing it in that variable, and if it isn't, then making the variable an empty string. So, something like this should work:...Code: Select all
if (isset(JFactory::getApplication()->JComponentTitle)) { $title = JFactory::getApplication()->JComponentTitle; } else { $title = ''; }
http://www.jdanielclements.com (Personal photography site)
http://www.coinzoo.net (World coin collection with animals)
http://www.coinzoo.net (World coin collection with animals)
- Webdongle
- Joomla! Master
- Posts: 44070
- Joined: Sat Apr 05, 2008 9:58 pm
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
If so, then perhaps it should have a tracker created for it ?
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"When I'm right no one remembers but when I'm wrong no one forgets".
https://www.weblinksonline.co.uk/updating-joomla.html
"When I'm right no one remembers but when I'm wrong no one forgets".
-
- Joomla! Apprentice
- Posts: 25
- Joined: Tue Oct 12, 2010 2:38 am
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
Have the same issue with extplorer, looping and all. Also with CE Contacts, and I know that Fox Contacts has the same problem. Also with OSEFileman.
PHP Built On Linux php-shared-1 2.6.32-5-amd64 #1 SMP Sun May 6 04:00:17 UTC 2012 x86_64
Database Version 5.5.27-rel28.1
Database Collation utf8_general_ci
PHP Version 5.3.14
Web Server LiteSpeed
WebServer to PHP Interface litespeed
Joomla! Version Joomla! 2.5.7 Stable [ Ember ] 13-September-2012 14:00 GMT
Joomla! Platform Version Joomla Platform 11.4.0 Stable [ Brian Kernighan ] 03-Jan-2012 00:00 GMT
User Agent Mozilla/5.0 (Windows NT 6.1; rv:16.0) Gecko/20100101 Firefox/16.0
PHP Built On Linux php-shared-1 2.6.32-5-amd64 #1 SMP Sun May 6 04:00:17 UTC 2012 x86_64
Database Version 5.5.27-rel28.1
Database Collation utf8_general_ci
PHP Version 5.3.14
Web Server LiteSpeed
WebServer to PHP Interface litespeed
Joomla! Version Joomla! 2.5.7 Stable [ Ember ] 13-September-2012 14:00 GMT
Joomla! Platform Version Joomla Platform 11.4.0 Stable [ Brian Kernighan ] 03-Jan-2012 00:00 GMT
User Agent Mozilla/5.0 (Windows NT 6.1; rv:16.0) Gecko/20100101 Firefox/16.0
-
- Joomla! Explorer
- Posts: 359
- Joined: Thu Jun 14, 2007 2:48 pm
- Location: Coppell, Texas
- Contact:
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
I am getting the same error with extplorer on one site. I have it installed on several other sites on the same server with no problems.
I have tried both changes above to the
/administrator/modules/mod_title/mod_title.php file. The error goes away but the
extplorer doesn't load the files. It just has a spinning wheel.
Has anyone else figured this out?
I have tried both changes above to the
/administrator/modules/mod_title/mod_title.php file. The error goes away but the
extplorer doesn't load the files. It just has a spinning wheel.
Has anyone else figured this out?
-
- Joomla! Ace
- Posts: 1500
- Joined: Fri Sep 29, 2006 4:59 pm
Re: Upgrade to Joomla 2.5.7 - mod_title.php error
I am getting this error message now on Joomla 2.5.9 after upgrading from Joomla 2.5.8.
Extplorer worked fine with Joomla 2.5.8 and is still working fine on my other websites, which I have not updated to Joomla 2.5.9 yet. I am not a programmer but would be interested to know if above mentioned changes would work in Joomla 2.5.9 and be save to apply.
Extplorer worked fine with Joomla 2.5.8 and is still working fine on my other websites, which I have not updated to Joomla 2.5.9 yet. I am not a programmer but would be interested to know if above mentioned changes would work in Joomla 2.5.9 and be save to apply.