Search code examples
javascriptjoomlajoomla2.5migratejoomla3.4

Why is core.js not loaded in Joomla 3?


I am migrating my own Joomla component from Joomla 2.5 to Joomla 3. Some of the buttons use javascript Joomla.submitform(), which was defined in \media\system\js\core.js, but somehow this file is not loaded any more now...

I could simply add JFactory::getDocument()->addScript( JURI::root().'media/system/js/core.js' ) to my component's code, but that seems the quick and dirty way to me.

Could someone tell me what the nice and clean way is? Help is very much appreciated!


Solution

  • Easy as pie

    JHtmlBehaviour::core();