MyBB Community Forums

Full Version: Error when setting reputation comments to 0, how not to show rep comments?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
We tinkered the reputation system and played with the different options. We turned off:

Reputation Comments Per Page

by setting the comments to display to 0.

But now every time someone visits the details of a user's reputation, this is the message that appears at the top of the page:

Warning [2] Division by zero - Line: 885 - File: inc/functions.php PHP 5.3.24 (Linux)

/inc/functions.php 885 errorHandler->error
/reputation.php 708 multipage

We just want to know if there's a way of not having the comments for the reputation show up. If we undo the 0 and put a positive number )e.g. 10), the error is removed.
Bump. Any please?
^ instead of the zero setting, I'd suggest to modify reputation template content

find code like below and remove it or use template conditionals plugin to hide the comments for regular members

<tr>
	<td class="tcat"><strong>{$lang->comments}</strong></td>
</tr>

{$reputation_votes}
<tr>
	<td class="tfoot" align="right">
	<form action="reputation.php" method="get">
		<input type="hidden" name="uid" value="{$user['uid']}" />
		<select name="show">
			<option value="all" {$show_selected['all']}>{$lang->show_all}</option>
			<option value="positive" {$show_selected['positive']}>{$lang->show_positive}</option>
			<option value="neutral" {$show_selected['neutral']}>{$lang->show_neutral}</option>
			<option value="negative" {$show_selected['negative']}>{$lang->show_negative}</option>
		</select>
		<select name="sort">
			<option value="dateline" {$sort_selected['last_updated']}>{$lang->sort_updated}</option>
			<option value="username" {$sort_selected['username']}>{$lang->sort_username}</option>
		</select>
		{$gobutton}
	</form>
	</td>
</tr>