Recoded McGeneric Template to work with Joomla