How do I restrict starting topics for lower ranks Hitskin_logo Hitskin.com

This is a Hitskin.com skin preview
Install the skinReturn to the skin page

The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.
4 posters

    How do I restrict starting topics for lower ranks

    Eleven
    Eleven
    Forumember


    Posts : 41
    Reputation : 2
    Language : English

    Solved How do I restrict starting topics for lower ranks

    Post by Eleven January 11th 2023, 7:40 pm

    Hi, I would like there to be a minimum of 10 posts before people can start topics in certain areas?


    Last edited by Eleven on January 12th 2023, 12:14 am; edited 2 times in total
    avatar
    Guest
    Guest


    Solved Re: How do I restrict starting topics for lower ranks

    Post by Guest January 11th 2023, 7:59 pm

    Tell me forum version and minimum posts required to open new topic by your standards.
    Eleven
    Eleven
    Forumember


    Posts : 41
    Reputation : 2
    Language : English

    Solved Re: How do I restrict starting topics for lower ranks

    Post by Eleven January 11th 2023, 8:04 pm

    Modernbb and a minimum of 5 posts to start topics 🙂
    avatar
    Guest
    Guest


    Solved Re: How do I restrict starting topics for lower ranks

    Post by Guest January 11th 2023, 8:07 pm

    I will write a script, give me some time Razz
    Eleven
    Eleven
    Forumember


    Posts : 41
    Reputation : 2
    Language : English

    Solved Re: How do I restrict starting topics for lower ranks

    Post by Eleven January 11th 2023, 8:08 pm

    Take your time I’ll get in front of a desktop tomorrow 🙂
    avatar
    Guest
    Guest


    Solved Re: How do I restrict starting topics for lower ranks

    Post by Guest January 11th 2023, 9:21 pm

    Go to CP - Modules - Javascript and make a new script. Name it "Disable new topics for low ranks" and past this code:
    Code:
    $(document).ready(function() {

        var total_posts = _userdata["user_posts"];
        var minimum_posts = 5;

        if (total_posts < minimum_posts) {
            $('a[href*="/post?f="][href*="&mode=newtopic"]').css("pointer-events", "none");
        }

    });

    Apply in all pages. Variable
    Code:
    minimum_posts
    is your own choise on how many posts user must have before posting a new message.
    If you want button completely gone, you can just say:

    Code:
    $(document).ready(function() {

        var total_posts = _userdata["user_posts"];
        var minimum_posts = 5;

        if (total_posts < minimum_posts) {
          $('a[href*="/post?f="][href*="&mode=newtopic"]').css("display", "none");
        }

    });
    Niko
    Niko
    Helper
    Helper


    Male Posts : 3229
    Reputation : 248
    Language : English, Italian, French
    Location : Italy

    Solved Re: How do I restrict starting topics for lower ranks

    Post by Niko January 11th 2023, 9:53 pm

    Coucou,

    the other solution, with only the native forumotion features would be to:
    • Create a group adding the automatic option to include only members with X posts published
      How do I restrict starting topics for lower ranks Screen37

    • Modify the permission of the different forums/sub-forums/blogs to allow posting only to members that are part of this group

    • Done :wouhou:


    Ape likes this post

    avatar
    Guest
    Guest


    Solved Re: How do I restrict starting topics for lower ranks

    Post by Guest January 11th 2023, 10:04 pm

    Niko wrote:Coucou,

    the other solution, with only the native forumotion features would be to:
    • Create a group adding the automatic option to include only members with X posts published
      How do I restrict starting topics for lower ranks Screen37

    • Modify the permission of the different forums/sub-forums/blogs to allow posting only to members that are part of this group

    • Done :wouhou:



    Isn't that much complicated that simple script? xD
    Niko
    Niko
    Helper
    Helper


    Male Posts : 3229
    Reputation : 248
    Language : English, Italian, French
    Location : Italy

    Solved Re: How do I restrict starting topics for lower ranks

    Post by Niko January 11th 2023, 10:23 pm

    @System32 using the native functions you can choose easily WHERE they cannot open new topics in that scenario

    because if you allow only people with 5 messages to open a new topic, then new members will never be able to reach those 5 posts because they will never be able to open a topic (it's a loop) farao

    Eleven likes this post

    avatar
    Guest
    Guest


    Solved Re: How do I restrict starting topics for lower ranks

    Post by Guest January 11th 2023, 10:29 pm

    Niko wrote:@System32 using the native functions you can choose easily WHERE they cannot open new topics in that scenario

    because if you allow only people with 5 messages to open a new topic, then new members will never be able to reach those 5 posts because they will never be able to open a topic (it's a loop) farao
    They will be able if they post in already opened topics.
    Ape
    Ape
    Administrator
    Administrator


    Male Posts : 19316
    Reputation : 2005
    Language : fluent in dork / mumbojumbo & English haha

    Solved Re: How do I restrict starting topics for lower ranks

    Post by Ape January 11th 2023, 11:26 pm

    The more Javascripts you have the more problems you will have with slowing your forum down or a clash on codes on the system if you have a tool already made for this then why use a code? You are always told to use the ones tested on the Admin page before making a change with codes.

    I would have gone with what @Niko has posted it's much better then using a code but I guess the choice is there for the member who wanted the help.



    How do I restrict starting topics for lower ranks Left1212How do I restrict starting topics for lower ranks Center11How do I restrict starting topics for lower ranks Right112
    How do I restrict starting topics for lower ranks Ape_b110
    How do I restrict starting topics for lower ranks Ape1010

    Niko and Eleven like this post

    Eleven
    Eleven
    Forumember


    Posts : 41
    Reputation : 2
    Language : English

    Solved Re: How do I restrict starting topics for lower ranks

    Post by Eleven January 11th 2023, 11:43 pm

    The only topics that will have this rule is for advertising, not for everywhere. 🙂 thank you for the help it works 👍

    Niko likes this post

    Ape
    Ape
    Administrator
    Administrator


    Male Posts : 19316
    Reputation : 2005
    Language : fluent in dork / mumbojumbo & English haha

    Solved Re: How do I restrict starting topics for lower ranks

    Post by Ape January 11th 2023, 11:46 pm

    @Eleven If this topic is now solved Please press the marked solved button found at the top of this topic.

    Please remember to do this on all solved topic's

    Thank you.

    Ape.



    How do I restrict starting topics for lower ranks Left1212How do I restrict starting topics for lower ranks Center11How do I restrict starting topics for lower ranks Right112
    How do I restrict starting topics for lower ranks Ape_b110
    How do I restrict starting topics for lower ranks Ape1010
    SLGray
    SLGray
    Administrator
    Administrator


    Male Posts : 51497
    Reputation : 3523
    Language : English
    Location : United States

    Solved Re: How do I restrict starting topics for lower ranks

    Post by SLGray January 12th 2023, 12:21 am

    Problem solved & topic archived.
    Please read our forum rules:  ESF General Rules



    How do I restrict starting topics for lower ranks Slgray10

    When your topic has been solved, ensure you mark the topic solved.
    Never post your email in public.