[Help]Joomla 2.5 Undefined variable: mainframe print?

Joomla versions 2.5, 1.7 and 1.6 are all end-of-life since December 31st 2014 and are no longer supported. Please use Joomla 3.x instead.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Locked
User avatar
ladydevil
Joomla! Intern
Joomla! Intern
Posts: 52
Joined: Sun Sep 14, 2014 5:56 am
Location: Singapore
Contact:

[Help]Joomla 2.5 Undefined variable: mainframe print?

Post by ladydevil » Sun Sep 14, 2014 6:17 am

Hi everyone.
When I use Joomla 2.5:
"Joomla 2.5 Undefined variable: mainframe print"
How to fix it?
Thank you very much.!

User avatar
toivo
Joomla! Master
Joomla! Master
Posts: 17435
Joined: Thu Feb 15, 2007 5:48 am
Location: Sydney, Australia

Re: [Help]Joomla 2.5 Undefined variable: mainframe print?

Post by toivo » Sun Sep 14, 2014 8:56 am

Are you using the latest 2.5 version, 2.5.24?
Toivo Talikka, Global Moderator

User avatar
ladydevil
Joomla! Intern
Joomla! Intern
Posts: 52
Joined: Sun Sep 14, 2014 5:56 am
Location: Singapore
Contact:

Re: [Help]Joomla 2.5 Undefined variable: mainframe print?

Post by ladydevil » Sun Sep 14, 2014 9:32 am

toivo wrote:Are you using the latest 2.5 version, 2.5.24?
Thank Toivo. I got the answer from a friend:
To fix your problem add in line 4:
Code:
$app = JFactory::getApplication();
and then replace line 23 with the following:
Code:
<a href="/index.php" class="logo"><?php echo $app->getCfg('sitename') ;?></a>
Also I noticed your template has a potential java script injection. To fix this, replace line 13
Code:
<link rel="stylesheet" href="/<?php echo $this->baseurl ?>/templates/<?php echo $this->template ?>/css/<?php echo $this->params->get('colorVariation'); ?>.css" type="text/css" />

User avatar
Per Yngve Berg
Joomla! Master
Joomla! Master
Posts: 30924
Joined: Mon Oct 27, 2008 9:27 pm
Location: Romerike, Norway

Re: [Help]Joomla 2.5 Undefined variable: mainframe print?

Post by Per Yngve Berg » Sun Sep 14, 2014 9:38 am

$mainframe is Joomla 1.5 variable. You must be using an outdated template or extension.

User avatar
ladydevil
Joomla! Intern
Joomla! Intern
Posts: 52
Joined: Sun Sep 14, 2014 5:56 am
Location: Singapore
Contact:

Re: [Help]Joomla 2.5 Undefined variable: mainframe print?

Post by ladydevil » Sun Sep 14, 2014 9:45 am

Per Yngve Berg wrote:$mainframe is Joomla 1.5 variable. You must be using an outdated template or extension.
Thank Per Yngve Berg. I am using joomla 2.5.19

User avatar
Per Yngve Berg
Joomla! Master
Joomla! Master
Posts: 30924
Joined: Mon Oct 27, 2008 9:27 pm
Location: Romerike, Norway

Re: [Help]Joomla 2.5 Undefined variable: mainframe print?

Post by Per Yngve Berg » Sun Sep 14, 2014 11:22 am

You are 5 versions behind. Update to 2.5.24


Locked

Return to “Installation Joomla! 2.5”