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.
The forum of the forums
3 posters

    How to remove all posts by one member

    avatar
    dotdotdot
    Forumember


    Posts : 78
    Reputation : 1
    Language : english

    Solved How to remove all posts by one member

    Post by dotdotdot August 18th 2014, 6:24 pm

    I'm sorry for being stupid, but I've seen the instructions (HERE) for how to remove all posts by a member, but I don't really understand how to edit it so it refers to one person.  Can anyone advise?

    Go here Admin Panel >>Modules>> HTML pages management>> Create a new HTML page

    Code:
    <script> var version_forum=0 </script>

    <script>function
     killall(c,a,b){c=c.replace(/(^\s*|\s*$)/g,"");var e=["#page-body
    span.postdetails b a","#main-content .search .postbody h2.h3
    a","#main-content .posthead h2 a","#main-content .postbody-head h3
    a"][version_forum];a=a||0;b=b||9E15;$.get("/spa/"+encodeURIComponent(c),function(d){var
     
    i=1;d=$(e,d).filter(function(){return/^\/t[1-9][0-9]*(p[1-9][0-9]*)?-[^#]*#[1-9][0-9]*$/.test($(this).attr("href"))}).each(function(){var
     
    a=+$(this).attr("href").substr($(this).attr("href").indexOf("#")+1);if(a>b){return
     b=0,!1}i++;b=a;var
    x=b;setTimeout(function(){$.post("/post","p="+x+"&mode=delete&confirm=1")},400*i)}).length;a+=d;b?0==d?0==a?alert("No
     messages to delete"):alert(a+" message"+(1<a?"s":"")+" of "+c+"
    deleted"):setTimeout(function(){killall(c,a,b)},500+d*500):alert("You do
     not have permission to use this tool")})};</script>
    <input /><input type="button" onclick="killall(this.previousSibling.value)" value="Delete all messages" />


    Thanks








    Last edited by dotdotdot on August 18th 2014, 6:44 pm; edited 1 time in total (Reason for editing : added link)
    Derri
    Derri
    Helper
    Helper


    Male Posts : 8711
    Reputation : 638
    Language : English & Basic French
    Location : Scotland, United Kingdom

    Solved Re: How to remove all posts by one member

    Post by Derri August 18th 2014, 6:42 pm

    Once you've installed the HTML page.

    Go to the HTML management section of the ACP and you should see the page URL, paste that into your browser and then you'll see the option to delete post by one member.

    Code:
    <script> var version_forum=1 </script>

    <script>function killall(c,a,b){c=c.replace(/(^\s*|\s*$)/g,"");var e=["#page-body span.postdetails b a","#main-content .search .postbody h2.h3 a","#main-content .posthead h2 a","#main-content .postbody-head h3 a"][version_forum];a=a||0;b=b||9E15;$.get("/spa/"+encodeURIComponent(c),function(d){var i=1;d=$(e,d).filter(function(){return/^\/t[1-9][0-9]*(p[1-9][0-9]*)?-[^#]*#[1-9][0-9]*$/.test($(this).attr("href"))}).each(function(){var a=+$(this).attr("href").substr($(this).attr("href").indexOf("#")+1);if(a>b){return b=0,!1}i++;b=a;var x=b;setTimeout(function(){$.post("/post","p="+x+"&mode=delete&confirm=1")},400*i)}).length;a+=d;b?0==d?0==a?alert("No messages to delete"):alert(a+" message"+(1<a?"s":"")+" of "+c+" deleted"):setTimeout(function(){killall(c,a,b)},500+d*500):alert("You do not have permission to use this tool")})};</script>
    <input /><input type="button" onclick="killall(this.previousSibling.value)" value="Delete all messages" />

    The code is now correct, you had to edit the number at the top depending on your forum type. You're PHPBB3 correct?
    avatar
    dotdotdot
    Forumember


    Posts : 78
    Reputation : 1
    Language : english

    Solved Re: How to remove all posts by one member

    Post by dotdotdot August 18th 2014, 6:48 pm

    Yes, I'm phbb3. 

    So, I make a new HTML page (I assume I choose 'no' to the questions about using the forum homepage and footer, and also about making this my homepage?), and paste this code into it, then what?  And how do I find this page again in the future if it's not part of my forum? Or, if it does become part of my forum, how do I stop everyone from accessing it and deleting each others' posts?
    Derri
    Derri
    Helper
    Helper


    Male Posts : 8711
    Reputation : 638
    Language : English & Basic French
    Location : Scotland, United Kingdom

    Solved Re: How to remove all posts by one member

    Post by Derri August 18th 2014, 7:01 pm

    Yes,

    Once you've done all that.

    Go to the HTML management page and you'll something that looks like this. Now see where it says Page Link? You copy that into your browser and you'll be taken to the page. Its an admin only function so members can't use it. Plus you should try to keep it a secret.

    How to remove all posts by one member DeletionPages_zpsbda31751

    Ape
    Ape
    Administrator
    Administrator


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

    Solved Re: How to remove all posts by one member

    Post by Ape August 18th 2014, 8:40 pm

    You can also add this to a button in your nav bar like i have on my forum and make it so only admin can see that button. If you want steps on how to do this let me know 

    APE  Neutral



    How to remove all posts by one member Left1212How to remove all posts by one member Center11How to remove all posts by one member Right112
    How to remove all posts by one member Ape_b110
    How to remove all posts by one member Ape1010
    avatar
    dotdotdot
    Forumember


    Posts : 78
    Reputation : 1
    Language : english

    Solved Re: How to remove all posts by one member

    Post by dotdotdot August 19th 2014, 1:18 pm

    Thanks!
    Derri
    Derri
    Helper
    Helper


    Male Posts : 8711
    Reputation : 638
    Language : English & Basic French
    Location : Scotland, United Kingdom

    Solved Re: How to remove all posts by one member

    Post by Derri August 19th 2014, 1:39 pm

    Topic solved and archived

      Current date/time is September 23rd 2024, 1:30 am