Ok, I was installing the post count requirement MOD onto my forum. Well, when opening a forum, I get this error: Fatal error: Call to undefined function check_post_count_requirement() Code (markup): Any help would be appreciated.
It can't find the function. Have you included it if it's already written in a file, otherwise, write it. Dan
Which forum software? Which addon? Did you install it correctly into the desired directory? Have you activated the addon? Possibly, you have uploaded it to the wrong directory.
How do I know if it's already written? Here's what I was supposed to put in viewforum.php: // Check if user is allowed to bypass the requirements $postcount_bypass = FALSE; $sql = "SELECT b.group_bypass_post_req AS requirement FROM " . USER_GROUP_TABLE . " a, " . GROUPS_TABLE . " b WHERE user_id = " . $user->data['user_id'] . " AND a.group_id = b.group_id"; $result = $db->sql_query($sql); while ($membership = $db->sql_fetchrow($result)) { if ($membership['requirement'] == 1) { $postcount_bypass = TRUE; break; } } $db->sql_freeresult($result); // Check if the user has the required post count to view the forum if (check_post_count_requirement($forum_id,'view') == FALSE && $postcount_bypass == FALSE) { $user->setup('common'); $post1 = ($forum_data['forum_postcount_view'] == 1) ? $user->lang['POSTREQ_POST'] : $user->lang['POSTREQ_POSTS']; $remaining = ($forum_data['forum_postcount_view'] - $user->data['user_posts']); $post2 = ($remaining == 1) ? $user->lang['POSTREQ_POST'] : $user->lang['POSTREQ_POSTS']; $accesserror = sprintf($user->lang['POSTREQ_NOACCESS_VIEW'], $forum_data['forum_postcount_view'], $post1); if ($user->data['user_id'] != ANONYMOUS) { $neededposts = " " . sprintf($user->lang['POSTREQ_NOACCESS_MORE'], $remaining, $post2); } trigger_error($accesserror . $neededposts); } The red line is where the error supposedly is.
nvm, I fixed it. I felt like a dumbass when I figured out I forgot to edit /includes/functions.php. -_- Then again, it was kind of obvious....