Skip to content

Instantly share code, notes, and snippets.

@araneta
Created May 11, 2014 12:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save araneta/ee3de8e23f6b59824e7f to your computer and use it in GitHub Desktop.
Save araneta/ee3de8e23f6b59824e7f to your computer and use it in GitHub Desktop.
Joomla: fix global $mainframe variable:
//old code
  global $mainframe;
  $params = &$mainframe->getParams();
//in joomla 1.7/2.5
  $app = &JFactory::getApplication();
  $params = $app->getParams();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment