Jump to content

Recommended Posts

Posted

Hello everyone, hoping someone can assist with an issue we have. 

 

We started a forum many years ago, then during covid hit some hard times and did not had the means to keep moderators, now we have managed to come back and wish to restore the forum to it's reputable state.

However since then a flurry of spammers infiltrated the forum (>1000). 

Right now we are banning each user by hand via the front end moderator tool / interface / GUI.

However, I am hoping there is maybe a way to do this via the backend, perhaps a script or SQL query I can run that will essentially apply the ban functionality to all users between a specific date?

Any other suggestions?

Posted

There isnt a way in which you would be able to ban them in that manner, however as a suggestion, what you could do is create a group with no permissions and move them all to that group, if its something where you want to immediately remove their access.

Posted

Where do they come from geographically speaking? Abroad?

We use Cloudflare as a CDN and Firewall. Few country are banned (Russia, Korea, Ukraine, ...).

Most of the robots, spammers, etc ... come from country you don't need. So block all the country and salam.

Posted
6 minutes ago, Platinumwealth.co.za said:

The above approach is not effective. 

I need a way to ban (apply the "flag as spammer") everyone in a specific date range

There isnt a way in which to do this on the platform at the present time, unforunately

Posted (edited)

Can you share the SQL queries that are run when you press "Flag as Spammer" then I will create that function. 

The issue is >1000 spammers registered between January 2024 and March 2024 each only posting 1 to 10 replies. 

Manually flagging each one as spam will take months. 

Edited by Platinumwealth.co.za
Posted

I have moved this to our developer connection forum where you may get better assistance on that. Generally we would not share things that are not explicitly tested for that purpose

Posted

A query won't cut it. The flag as spammer function performs several actions based on the chosen settings.

 

You need a custom script that loads all the members and flags them 1-by-1. It's doable since I've done something similar for a client previously.

Posted
On 5/24/2024 at 9:04 AM, Platinumwealth.co.za said:

The above approach is not effective. 

I need a way to ban (apply the "flag as spammer") everyone in a specific date range

Hi,

I agree with teraByte - write a custom application to do this - you possibly only need one significant script file. I would guess it is less than 20 lines of script:

  • define 'where clause' ($where) that compares the join date against your date range
  • create iterator of selected Members: new \IPS\Patterns\ActiveRecordIterator( \IPS\Db::i()->select( '*', 'core_members', $where), 'IPS\Member' );
  • Loop through members calling ->flagAsSpammer()
  • At end of loop you're all done.

John

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...