-
AuthorPosts
-
November 15, 2006 at 10:37 pm #117661
Hi all,
I’m getting a ‘division by zero’ error:
Warning: Division by zero in /home/bthere36/domains/bthere4u.nl/public_html/templates/ja_pollux/index.php on line 40
Please take a look at http://85.17.55.2/~bthere36/index.php, here you can see the error. Does anyone know what that error means? It is at this line:
$ja_headerimg = $ja_header_images [getCurrentMenuIndex() % count($ja_header_images)];
in the index.php of the ja_pollux theme.
When I run the site ‘localhost’ then I’m not getting the error!:confused:
Thanx in advance…
November 15, 2006 at 10:45 pm #211684Additional info:
Following PHP Server Settings are not optimal for Security and it is recommended to change them:
PHP register_globals setting is `ON` instead of `OFF` Joomla! RG_EMULATION setting is `ON` instead of `OFF` in file globals.php
`ON` by default for compatibility reasonssecond additional:
Session Directory / Unwriteable
Could that cause anything wrong?
ha le-viet Developerha le-viet
- Join date:
- April 2006
- Posts:
- 415
- Downloads:
- 0
- Uploads:
- 26
- Thanked:
- 5 times in 1 posts
November 16, 2006 at 8:59 am #211707Hi jmvvliet,
Please replace that line by:
if (count($ja_header_images)) $ja_headerimg = $ja_header_images [getCurrentMenuIndex() % count($ja_header_images)];
Regards,
Ha Le-Viet.November 16, 2006 at 9:21 am #211709Ha-Le-Viet,
problem solved. But I’m always searching for the reason why… does the current menu index not contain a number > 0, or are there simply no ja_header_images?
By the way, I’m using Joomla! 1.0.11 and IE 7.0…
Thanx anyway,
JMvV
Omar Ramos JAECOmar Ramos
- Join date:
- September 2014
- Posts:
- 93
- Downloads:
- 154
- Uploads:
- 12
- Thanked:
- 15 times in 1 posts
January 19, 2007 at 12:07 am #213263The problem seems to lie in using the Dropline Menu Script, should you choose the Suckerfish menu, the error goes away.
Correct me if I’m wrong, but I think that’s what it is.
-Omar
January 19, 2007 at 2:06 pm #213281I’ve followed all the advice given in this post however the problem still exists on my site.
http://www.gorivercruise.co.uk
Can anyone assist me?
Regards,
ha le-viet Developerha le-viet
- Join date:
- April 2006
- Posts:
- 415
- Downloads:
- 0
- Uploads:
- 26
- Thanked:
- 5 times in 1 posts
January 27, 2007 at 3:48 am #213761Hi fredo,
I visited your site and see no error or warning message. Did you fix the problem?
Regards,
Ha Le-Viet.March 12, 2007 at 6:17 pm #215583Ha Le-Viet,
I had the error @ line 40 and your solution fixed it (Thank you for that), had the same template running on a different site and it did not have that error. Curious why one site would have it and one would not?? Can you detail “Why?” your solution fixed the error?
ha le-viet Developerha le-viet
- Join date:
- April 2006
- Posts:
- 415
- Downloads:
- 0
- Uploads:
- 26
- Thanked:
- 5 times in 1 posts
March 13, 2007 at 2:34 am #215613Hi filter2k,
The error will show if your webserver error display policy is set to E_ALL, E_NOTICE etc. Some server only reports errors when its status is Fatal or Normal Error and ignore warning and notice errors.
Regards,
Ha Le-Viet. -
AuthorPosts
This topic contains 10 replies, has 5 voices, and was last updated by filter2k 17 years, 8 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum