Fixed Joomla 2.5 compatibility, API fixes