- if ($color_index && isset($tab_colors[($tab_index)%count($tab_colors)])) {
- $id .= $tab_colors[($tab_index)%count($tab_colors)];
- $tab_index++;
Warning: Division by zero in rt_splitmenu.php
33 posts • Page 1 of 3 • 1, 2, 3
Hello All,
I use the ModernBusiness template and since a few days my page doesn't load right anymore and I get this messages:
Warning: Division by zero in D:\www\...\rt_splitmenu.php on line 63
My host did an update of php to 5.2.
Does anyone knows how to get rid of the error?
Much appreciated!
(I don't know if this is the right forum for this but because the ModernBusiness forum doesn't appear for me, I post this here.)
I use the ModernBusiness template and since a few days my page doesn't load right anymore and I get this messages:
Warning: Division by zero in D:\www\...\rt_splitmenu.php on line 63
My host did an update of php to 5.2.
Does anyone knows how to get rid of the error?
Much appreciated!
(I don't know if this is the right forum for this but because the ModernBusiness forum doesn't appear for me, I post this here.)
- J.M. Sanders
- Newbie

- Posts: 10
do you any items in the menu used by splitmenu? probably main menu?
-

Andy Miller - Team RocketTheme

- Posts: 6878
- Location: Golden, CO
Thank you for replying! Yes I use the main menu. Don't know excactly what you mean.
- J.M. Sanders
- Newbie

- Posts: 10
I also suddenly got the warning:
I see it in both FireFox and IE7
It "suddenly" appeared, and I am pretty sure I didn't see it last time I updated my site.
If I chose "module" in stead of "splitmenu" in the config for template it (the warning) doesn't show (of cource).
It doesn't matter wether if I put a "sub-menu item" into the main menu or not.
How can this be? - What do you believe is the case?
Warning: Division by zero in /home/mysite/public_html/templates/rt_modbusiness/rt_splitmenu.php on line 63
Warning: Division by zero in /home/mysite/public_html/templates/rt_modbusiness/rt_splitmenu.php on line 63
Warning: Division by zero in /home/mysite/public_html/templates/rt_modbusiness/rt_splitmenu.php on line 63
Warning: Division by zero in /home/mysite/public_html/templates/rt_modbusiness/rt_splitmenu.php on line 63
I see it in both FireFox and IE7
It "suddenly" appeared, and I am pretty sure I didn't see it last time I updated my site.
If I chose "module" in stead of "splitmenu" in the config for template it (the warning) doesn't show (of cource).
It doesn't matter wether if I put a "sub-menu item" into the main menu or not.
How can this be? - What do you believe is the case?
- Preben Olsen Sangvik
- Newbie

- Posts: 14
Now it's all gone - without me changing anything. It might be a server problem(!) ???
- Preben Olsen Sangvik
- Newbie

- Posts: 14
I still have this problem. My site is 'down' because of this error. No solutions?
Thx in advance.
Thx in advance.
- J.M. Sanders
- Newbie

- Posts: 10
Sorry, the problem remains...
It looked it did work due to a DNS that showed the old site...
The problems still remains...
It looked it did work due to a DNS that showed the old site...
The problems still remains...
- Preben Olsen Sangvik
- Newbie

- Posts: 14
Line 63 says:
- Preben Olsen Sangvik
- Newbie

- Posts: 14
what value do you have for $tab_colors at the top of the file?
-

Andy Miller - Team RocketTheme

- Posts: 6878
- Location: Golden, CO
actually, probalby best to send me your whole rt_splitmenu.php file to support(a)rockettheme.com
-

Andy Miller - Team RocketTheme

- Posts: 6878
- Location: Golden, CO
Email sent... :-)
I guess it's the original file (can't remember that I have modded this one...)
I guess it's the original file (can't remember that I have modded this one...)
- Preben Olsen Sangvik
- Newbie

- Posts: 14
the file looks fine.. the only place i can see that a division by zero error would occur is with the modulus operator (%), and that means $tab_color would have to be zero which makes no sense as tab_color is a global here. Only thing i can think of is on line 62 put:
$tab_color = 'white';
$tab_color = 'white';
-

Andy Miller - Team RocketTheme

- Posts: 6878
- Location: Golden, CO
Do you mean like this: (?)
$tab_color = 'white'; / on line 62 ...
Didn't work. See www.sangvik.com
- $tab_color = 'white';
- if ($color_index && isset($tab_colors[($tab_index)%count($tab_colors)])) {
- $id .= $tab_colors[($tab_index)%count($tab_colors)];
- $tab_index++;
$tab_color = 'white'; / on line 62 ...
Didn't work. See www.sangvik.com
- Preben Olsen Sangvik
- Newbie

- Posts: 14
quick fix, replace that line 62 you just added with:
error_reporting(0);
error_reporting(0);
-

Andy Miller - Team RocketTheme

- Posts: 6878
- Location: Golden, CO
33 posts • Page 1 of 3 • 1, 2, 3
Who is online
Users browsing this forum: Google [Bot] and 0 guests
