The Joomla! Forum ™



Forum rules


Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.



Post new topic Reply to topic  [ 18 posts ] 
Author Message
PostPosted: Mon Jan 10, 2011 8:38 pm 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Jan 10, 2011 8:27 pm
Posts: 12
When I install a new template to Joomla! Version 1.5.22, on my homepage above the content on the white background it says:

Notice: Undefined index: ALL_HTTP in /var/www/html/websitename/templates/nameofthetemplate/index.php on line 28

Notice: Undefined variable: user123 in /var/www/html/websitename/templates/nameofthetemplate/layouts/default/header.php on line 9

Notice: Undefined variable: user45 in /var/www/html/websitename/templates/nameofthetemplate/layouts/default/header.php on line 15

PHP on this server is : 5.2.13


Last edited by violinar on Tue Jan 11, 2011 10:50 am, edited 1 time in total.

Top
 Profile  
 
PostPosted: Mon Jan 10, 2011 8:41 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Sat Apr 05, 2008 9:58 pm
Posts: 25005
Location: @Webdongle
Local or remote install ?

Custom Template ?

_________________
'When I'm right nobody remembers when I'm wrong nobody forgets.'

http://weblinksonline.co.uk/joomla-faq.html


Top
 Profile  
 
PostPosted: Mon Jan 10, 2011 8:52 pm 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Jan 10, 2011 8:27 pm
Posts: 12
I've been installing Joomla! using FileZilla FTP Client.

Here I've found free templates http://www.joomla24.com/ which perfectly function on my other Joomla! (Version 1.5.21) website (which is on another server).

This server (where is Joomla! which has problems with installing new templates) is on Linux.


Top
 Profile  
 
PostPosted: Mon Jan 10, 2011 8:54 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Sat Apr 05, 2008 9:58 pm
Posts: 25005
Location: @Webdongle
Look at Joomla admin >>>> Help >>> System info ... Directory permissions Tab

What does it say ?

_________________
'When I'm right nobody remembers when I'm wrong nobody forgets.'

http://weblinksonline.co.uk/joomla-faq.html


Top
 Profile  
 
PostPosted: Mon Jan 10, 2011 9:01 pm 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Jan 10, 2011 8:27 pm
Posts: 12
Everything was writable (today afternoon) but still I keep receiving those annoying notes. This evening I've reinstalled Joomla! but everything became unwritable with the same annoying notes on the website page (after installing new templates). Right now I'm making everything writable again, and I will let you know if anything changed (but I doubt that Undefined index / variable notes are gone).

I was searching a lot on Joomla! forum for the answer, but it seams that I'm the only one who get Undefined index / variable notes after installing new templates...

I must tell you that each template has it's own note. Here is another message which I keep receiving above the content:

Notice: Undefined variable: my in /var/www/html/websitename/templates/templatename/index.php on line 34

Notice: Trying to get property of non-object in /var/www/html/websitename/templates/templatename/index.php on line 34


Top
 Profile  
 
PostPosted: Mon Jan 10, 2011 9:17 pm 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Jan 10, 2011 8:27 pm
Posts: 12
Webdongle wrote:
Look at Joomla admin >>>> Help >>> System info ... Directory permissions Tab

What does it say ?


Everything is writable.


Top
 Profile  
 
PostPosted: Mon Jan 10, 2011 9:39 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Sat Apr 05, 2008 9:58 pm
Posts: 25005
Location: @Webdongle
It appears that your Template is asking for a variable that it (or one of it's files) did not define. Either because the person who designed the Template forgot to put it in or because the index.php file can not find/read the file it is defined in.

http://en.wikipedia.org/wiki/Undefined_variable

_________________
'When I'm right nobody remembers when I'm wrong nobody forgets.'

http://weblinksonline.co.uk/joomla-faq.html


Top
 Profile  
 
PostPosted: Mon Jan 10, 2011 9:43 pm 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Jan 10, 2011 8:27 pm
Posts: 12
Webdongle wrote:
It appears that your Template is asking for a variable that it (or one of it's files) did not define. Either because the person who designed the Template forgot to put it in or because the index.php file can not find/read the file it is defined in.

http://en.wikipedia.org/wiki/Undefined_variable


With every template which I install I receive notes/errors. So, I doubt that all of the designers made the same mistake.

If index.php can't find/read the file, what should I do?


Top
 Profile  
 
PostPosted: Mon Jan 10, 2011 9:52 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Sat Apr 05, 2008 9:58 pm
Posts: 25005
Location: @Webdongle
It must be a path or permissions issue

What is the url ?

_________________
'When I'm right nobody remembers when I'm wrong nobody forgets.'

http://weblinksonline.co.uk/joomla-faq.html


Top
 Profile  
 
PostPosted: Mon Jan 10, 2011 9:59 pm 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Jan 10, 2011 8:27 pm
Posts: 12
Webdongle wrote:
It must be a path or permissions issue

What is the url ?


Last edited by violinar on Tue Jan 11, 2011 10:21 am, edited 1 time in total.

Top
 Profile  
 
PostPosted: Mon Jan 10, 2011 10:16 pm 
User avatar
Joomla! Master
Joomla! Master

Joined: Sat Apr 05, 2008 9:58 pm
Posts: 25005
Location: @Webdongle
The output is
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="<br />
<b>Notice</b>:  Use of undefined constant _LANGUAGE - assumed '_LANGUAGE' in <b>/var/www/html/stradivari/templates/morit/index.php</b> on line <b>25</b><br />
_LANGUAGE" xml:lang="<br />
<b>Notice</b>:  Use of undefined constant _LANGUAGE - assumed '_LANGUAGE' in <b>/var/www/html/stradivari/templates/morit/index.php</b> on line <b>25</b><br />
_LANGUAGE">

<head>



So it is complaining about (see the line ?
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $this->language; ?>" lang="<?php echo $this->language; ?>" >
<head>



Then it complains about
Code:
<script type="text/javascript" src="/media/system/js/caption.js"></script>

   <br />
<b>Notice</b>:  Undefined variable: my in <b>/var/www/html/stradivari/templates/morit/index.php</b> on line <b>36</b><br />
<br />
<b>Notice</b>:  Trying to get property of non-object in <b>/var/www/html/stradivari/templates/morit/index.php</b> on line <b>36</b><br />

   <meta http-equiv="Content-Type" content="text/html; <br />

_________________
'When I'm right nobody remembers when I'm wrong nobody forgets.'

http://weblinksonline.co.uk/joomla-faq.html


Top
 Profile  
 
PostPosted: Tue Jan 11, 2011 9:25 am 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Jan 10, 2011 8:27 pm
Posts: 12
Thank you Webdongle. Could you tell me how can I fix that? Which file (index.php ?) should I edit (and which information should I type)?


Top
 Profile  
 
PostPosted: Tue Jan 11, 2011 9:31 am 
User avatar
Joomla! Hero
Joomla! Hero

Joined: Mon Sep 21, 2009 6:56 am
Posts: 2068
Location: indore,india
hi violinar,
in live site you you want to show the warning and message.not a good practice.
open
/var/www/html/stradivari/templates/morit/index.php
after line
defined( '_JEXEC' ) or die( 'Restricted access' );
add this line
Code:
error_reporting(0);


Regards
Abhijeet

_________________
abhijeet kurchania
The future depends on what you do today


Top
 Profile  
 
PostPosted: Tue Jan 11, 2011 10:17 am 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Jan 10, 2011 8:27 pm
Posts: 12
Thank you Abhijeet! You solve the problem!
Now I apply that code to all new templates which I install...


Top
 Profile  
 
PostPosted: Tue Jan 11, 2011 10:39 am 
User avatar
Joomla! Hero
Joomla! Hero

Joined: Mon Sep 21, 2009 6:56 am
Posts: 2068
Location: indore,india
hi violinar,
also you can go to
http://docs.joomla.org/Screen.config.15#Server
you can see error_reporting option there.
make it to none.
please close the topic by marking right button or write at header solved.

Regards
Abhijeet

_________________
abhijeet kurchania
The future depends on what you do today


Top
 Profile  
 
PostPosted: Tue Jan 11, 2011 10:49 am 
User avatar
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Jan 10, 2011 8:27 pm
Posts: 12
Done! Thanks again!


Top
 Profile  
 
PostPosted: Fri Jul 22, 2011 5:00 am 
Joomla! Fledgling
Joomla! Fledgling

Joined: Fri Jul 22, 2011 4:44 am
Posts: 3
Webdongle wrote:
Local or remote install ?

Custom Template ?


Hy...i have the same problem with joomla 1.5 im using themza_j15_26 ... *


Notice: Undefined variable: title in C:\wamp\www\Joomla 1.5.23\templates\themza_j15_26\functions.php on line 172

how do i fix it ???pls help


Top
 Profile  
 
PostPosted: Fri Jul 22, 2011 11:20 am 
User avatar
Joomla! Master
Joomla! Master

Joined: Sat Apr 05, 2008 9:58 pm
Posts: 25005
Location: @Webdongle
viewtopic.php?p=1673083#p1673083

_________________
'When I'm right nobody remembers when I'm wrong nobody forgets.'

http://weblinksonline.co.uk/joomla-faq.html


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 18 posts ] 



Who is online

Users browsing this forum: No registered users and 24 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group