I have a URL...
/index.php?option=com_docman&task=doc_download&gid= // many gid's
I want to use an NGINX location block with a wildcard to "DENY ALL" any urls containing "option=com_docman"
In various regex testers....
^(.*)(option)(.*)(com_docman)$ // Works fine for normal regex
However when testing in my nginx.conf file... the following does not work.
location ~ ^(.*)(option)(.*)(com_docman)(.*)$ {
Deny All;
}
Bonus Is there a way to get robots.txt to address wildcard urls in the same way?
Edit Not sure why downvoted... anyone want to tell me what obvious thing i'm doing wrong here?