0

My stats show that a lot of bots are abusing the internal wordpress search functionality of my site:

www.yinlingjiaoyu.cn
9
www.scckym.cn
9
www.gzcq1688.cn
9
www.mindswift.cn
8
www.ytgso.cn
8
www.annlin.cn
8
www.lfysjy.cn

Is there a way to prevent this from happening? I.e. if a search begins with www. then block it ?

1 Answer 1

0

I suggest using a security plugin which will do everything for you. Like iThemes Security

Bans troublesome user agents, bots and other hosts

https://wordpress.org/plugins/better-wp-security/

1
  • Is there a custom function I could use instead?
    – JoaMika
    Commented Feb 5, 2021 at 13:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.