php - Using .htaccess to block URL containing a keyword only if it is not containing another keyword -


this odd situation, hammering our servers http requests trying access different tinymce based editors. want block url containing keyword editor have valid working urls containing same word ... example letter-from-editor.html or editorial-board.html

is there way using .htaccess can contain url containing keyword editor if doesn't contain keyword html ?

this trying right blocks editor only

rewriterule (^|/)editor(/|$) - [f,l] 

i searched , couldn't find way around it. thanks

you need add simple condition:

rewritecond %{request_uri} !html rewriterule (^|/)editor(/|$) - [f,l] 

Comments

Popular posts from this blog

java - Plugin org.apache.maven.plugins:maven-install-plugin:2.4 or one of its dependencies could not be resolved -

Round ImageView Android -

How can I utilize Yahoo Weather API in android -