Public
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Occasional Advisor

Block spam users from different countries

Dear Team,

 

HDFC community has more than 17000 registered users from which only 600 users are valid. We tried to block them using client side scripting but it didn't work as they blocked client side scripting from their browsers.

 

I have attached script which I used to block spam users from registering by using their geolocation. In our case users belong to India are allowed to sign up. 

 

I want you to implement something like this from server side.

 

-- When user is redirected to registration page alert message saying that you are not allowed to sign up from this region.

 

Hope to hear from you soon.


BlockUsersFromRegistering.pngBlockUserScript.png
3 Replies 3
Honored Contributor

@hayat_sama - You can do this on the page initialization script instead.


Varun : Weaving magic with Khoros!

Recent Ideas: Advanced Private Messages | Rewarding Module | Badges for Threads

Thanks for the quick reply Varun. 

 

But other country users are disabling client scripts. So any code written in javascript won't work. Do you have any thought about this?

 

 

@hayat_sama - You can use the page init script that enables you to execute business logic using FreeMarker early in a request before any HTML being rendered. This script runs once each request, server-side, and is often used for redirecting to a different page and reskinning pages in the community. You'll need to check and write your business logic accordingly. 


Varun : Weaving magic with Khoros!

Recent Ideas: Advanced Private Messages | Rewarding Module | Badges for Threads

Welcome to the Technology board!

Curious about our platform? Looking to connect on social technology? You've come to the right place!

Are you a Khoros customer? For direct assistance from our Support team, please visit the Support Forum.