News:

Wondering if this will always be free?  See why free is better.

Main Menu

Word Count Limits

Started by ethankcvds, September 08, 2009, 11:53:09 PM

Previous topic - Next topic

Sefket

So uh, should I just manually edit instead of installing the package?

ethankcvds

Quote from: Sefket on November 26, 2011, 08:32:43 PM
So uh, should I just manually edit instead of installing the package?

You just need to manually edit that one part of the file. Then after you've made that edit you can use the package manager to install the mod whilst ignoring the error about the failed test.
No Pm's for support please!

Sefket

So it'd be this:

{
// Some things that need to be setup for a new board.
$curBoard = array(
'memberGroups' => array(0, -1),
'category' => (int) $_REQUEST['cat']
);
$context['board_order'] = array();
$context['board'] = array(
'is_new' => true,
'id' => 0,
'name' => $txt['mboards_new_board_name'],
'description' => '',
'count_posts' => 1,
'theme' => 0,
'override_theme' => 0,
'category' => (int) $_REQUEST['cat'],
'no_children' => true,
'is_redirect' => 0,
'count_clicks' => 0,
'target' => '',
'url' => '',
);
'min_words' => 0,
         'max_words' => 0,
}
else
{
// Just some easy shortcuts.
$curBoard = &$boards[$_REQUEST['boardid']];
$context['board'] = $boards[$_REQUEST['boardid']];
$context['board']['name'] = htmlspecialchars($context['board']['name']);
$context['board']['description'] = htmlspecialchars($context['board']['description']);
$context['board']['no_children'] = empty($boards[$_REQUEST['boardid']]['tree']['children']);
$context['board']['sort_method'] = $curBoard['sort_method'];
$context['board']['sort_order'] = $curBoard['sort_order'];
}

ethankcvds

Quote from: Sefket on November 26, 2011, 08:40:30 PM
So it'd be this:

{
      // Some things that need to be setup for a new board.
      $curBoard = array(
         'memberGroups' => array(0, -1),
         'category' => (int) $_REQUEST['cat']
      );
      $context['board_order'] = array();
      $context['board'] = array(
         'is_new' => true,
         'id' => 0,
         'name' => $txt['mboards_new_board_name'],
         'description' => '',
         'count_posts' => 1,
         'theme' => 0,
         'override_theme' => 0,
         'category' => (int) $_REQUEST['cat'],
         'no_children' => true,
         'is_redirect' => 0,
         'count_clicks' => 0,
         'target' => '',
         'url' => '',
      );
      'min_words' => 0,
         'max_words' => 0,
   }
   else
   {
      // Just some easy shortcuts.
      $curBoard = &$boards[$_REQUEST['boardid']];
      $context['board'] = $boards[$_REQUEST['boardid']];
      $context['board']['name'] = htmlspecialchars($context['board']['name']);
      $context['board']['description'] = htmlspecialchars($context['board']['description']);
      $context['board']['no_children'] = empty($boards[$_REQUEST['boardid']]['tree']['children']);
      $context['board']['sort_method'] = $curBoard['sort_method'];
      $context['board']['sort_order'] = $curBoard['sort_order'];
   }


Close
{
      // Some things that need to be setup for a new board.
      $curBoard = array(
         'memberGroups' => array(0, -1),
         'category' => (int) $_REQUEST['cat']
      );
      $context['board_order'] = array();
      $context['board'] = array(
         'is_new' => true,
         'id' => 0,
         'name' => $txt['mboards_new_board_name'],
         'description' => '',
         'count_posts' => 1,
         'theme' => 0,
         'override_theme' => 0,
         'category' => (int) $_REQUEST['cat'],
         'no_children' => true,
         'is_redirect' => 0,
         'count_clicks' => 0,
         'target' => '',
         'url' => '',
         'min_words' => 0,
          'max_words' => 0,
      );
   }
   else
   {
      // Just some easy shortcuts.
      $curBoard = &$boards[$_REQUEST['boardid']];
      $context['board'] = $boards[$_REQUEST['boardid']];
      $context['board']['name'] = htmlspecialchars($context['board']['name']);
      $context['board']['description'] = htmlspecialchars($context['board']['description']);
      $context['board']['no_children'] = empty($boards[$_REQUEST['boardid']]['tree']['children']);
      $context['board']['sort_method'] = $curBoard['sort_method'];
      $context['board']['sort_order'] = $curBoard['sort_order'];
   }
No Pm's for support please!

Sefket

Worked, thank you. Do you know how to code it so it doesn't let people quote someones reply and not put text in their post?

ethankcvds

Quote from: Sefket on November 26, 2011, 08:57:24 PM
Worked, thank you. Do you know how to code it so it doesn't let people quote someones reply and not put text in their post?

I've got it somewhat working I just need to fix a few small issues.
No Pm's for support please!

Sefket

Glad to hear. If I knew how to code, I wouldn't brag you, haha. This is a great modification. Can't wait for you to finish coding that part :) .

pikeman


TheoOule

Is there any chance that the Word Limit mod package could be updated for the current release?

dougiefresh

#69
Very unlikely that ethankcvds will do so, as he was last active on the forum on December 30, 2013.  And lack of a license in the mod packaging is treated as no license to do anything with the package by the SMF team.

UPDATE:  Just tried installing this mod on SMF 2.0.15.  Looks like it installs just fine, even without using version emulation....

Shambles

Quote from: TheoOule
... updated for the current release?

What release would that be?

ethankcvds

It should install fine on future versions of 2.0.x the only problem is other mods and potential updates for security issues. For 2.1.x I need to edit somethings to make it work.
No Pm's for support please!

ethankcvds

Quick update:


Version 1.4 RC(hopefully released soon!) change log:
Dropped support for SMF 1.1
Added support for SMF 2.1 RC2
Quoted posts no longer included in word  count total.

No Pm's for support please!

Advertisement: