Support

Admin Tools

#12437 Fixed related to ticket #10798

Posted in ‘Admin Tools for Joomla! 4 & 5’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
n/a
PHP version
n/a
Admin Tools version
n/a

Latest post by nicholas on Saturday, 26 May 2012 11:52 CDT

user7136
Mandatory information about my setup:

Have I read the related troubleshooter articles above before posting (which pages?)? YES
Have I searched the tickets before posting? YES
Have I read the documentation before posting (which pages?)? YES
Joomla! version: 1.5.xx / 2.5.xx)
PHP version: 5.3.13
MySQL version: 5.1.63
Host: (optional, but it helps us help you)
Admin Tools version: PRO 2.2.6

Description of my issue:
The issue with the old ticket #10798 was:
PHP Fatal error:  Call to protected method JRequest::_cleanVar() from context 'FOFInput' in /home/-----/public_html/administrator/components/com_admintools/fof/input.php on line 39


And so, yes I got a modified version of the /libraries/joomla/environment/request.php
This file have this modifications to be full compliant with PHP5.3

lines 516 / 548 / 591 just added in front of each "fucntion":
	static protected 

And this was the issue, so just changed it to:
	static public 


And so Admintools is now at works.

But I don't know if this is a good idea...perhaps roll back to the original joomla file is much better rather than PHP5.3 full compliance, what do you think of that ?
thanks

nicholas
Akeeba Staff
Manager
OK, I'll tell you what I think.

First, you should never, EVER modify core Joomla! code. If you decide to do that, please do not request support from any developer. We can not provide support for arbitrarily modified versions of Joomla!.

Second thing to notice is that your change made the static methods protected. As you can see in the current source code tree these methods are declared without a visibility specifier which makes them implicitly public. By making them explicitly protected you broke Joomla!'s API.

Rule of thumb: do not touch the code unless you fully understand the consequences of your actions and are willing to accept the cost of cleaning up after yourself :)

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

user7136
^^
ok, thanks for advices nicholas.

Wasn't warned before because Admintools were the first one to stop working with this hack.
If so, I would have rolled back to the original since a long time.
My mistake...I'm alive!!

;-) Thanks a lot.

nicholas
Akeeba Staff
Manager
As some of my friends (also developers) put it: whenever you hack core, Joomla! developers kill a kitten :D Now you know what to do and, most importantly, what not to do :)

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!