Make .htaccess redirect spamy links that start with ? to an error page
-
I have tried lots of code and now I’m here. Is there a way I can redirect spamy links back to a 404 error or 410 error gone page, through my .htaccess file (it’s a wordpress site) the links all start with a ? mark – so for example they are: https://www.mydomain.com/?spam-link-here link, right now they are all going to the home page and I would like them to go to either a 404 or 410 error page. So it needs to be something that targets a query string that starts with a ? mark targeted code.
**FYI I have hardened my htaccess file, just need help with this part, if possible!
THANK YOU AHEAD OF TIME!
Viewing 11 replies - 1 through 11 (of 11 total)
Viewing 11 replies - 1 through 11 (of 11 total)
- The topic ‘Make .htaccess redirect spamy links that start with ? to an error page’ is closed to new replies.