00830: Message "Warning: division by zero" when using tables

Summary: Message "Warning: division by zero" when using tables
Created: 2006-11-09 09:19
Status: Closed - fixed in 2.1.27
Category: Bug
From:
Assigned:
Priority: 4
Version: latest stable
OS: ?

Description: On every page wiki page i use tables i get the following error message: Warning: Division by zero in pmwiki.php on line 1158

Website: www.ralfpichler.net

Please have a look at this issue! Feedback eMail: ralfpichler(at)googlemail.com


Solution Change in line 1100 of pmwiki.php $FmtV['$TableRowIndex'] = ($rowcount % $TableRowIndexMax) + 1;

to

$FmtV['$TableRowIndex'] = @($rowcount % $TableRowIndexMax) + 1;

It will oppress the warning message!


An even better solution (that doesn't require modifying pmwiki.php) is to set $TableRowIndexMax = 1; in local/config.php .

Pm