mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 06:08:52 +00:00
- check for zero user_posts
git-svn-id: file:///svn/phpbb/trunk@5041 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
52f17c49d7
commit
cf1d36aa77
1 changed files with 2 additions and 2 deletions
|
@ -235,7 +235,7 @@ class ucp_main extends module
|
||||||
$active_f_name = $active_f_row['forum_name'];
|
$active_f_name = $active_f_row['forum_name'];
|
||||||
$active_f_id = $active_f_row['forum_id'];
|
$active_f_id = $active_f_row['forum_id'];
|
||||||
$active_f_count = $active_f_row['num_posts'];
|
$active_f_count = $active_f_row['num_posts'];
|
||||||
$active_f_pct = ($active_f_count / $user->data['user_posts']) * 100;
|
$active_f_pct = ($user->data['user_posts']) ? ($active_f_count / $user->data['user_posts']) * 100 : 0;
|
||||||
}
|
}
|
||||||
unset($active_f_row);
|
unset($active_f_row);
|
||||||
|
|
||||||
|
@ -245,7 +245,7 @@ class ucp_main extends module
|
||||||
$active_t_name = $active_t_row['topic_title'];
|
$active_t_name = $active_t_row['topic_title'];
|
||||||
$active_t_id = $active_t_row['topic_id'];
|
$active_t_id = $active_t_row['topic_id'];
|
||||||
$active_t_count = $active_t_row['num_posts'];
|
$active_t_count = $active_t_row['num_posts'];
|
||||||
$active_t_pct = ($active_t_count / $user->data['user_posts']) * 100;
|
$active_t_pct = ($user->data['user_posts']) ? ($active_t_count / $user->data['user_posts']) * 100 : 0;
|
||||||
}
|
}
|
||||||
unset($active_t_row);
|
unset($active_t_row);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue