Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: htaccess suggestions
Nope, that also stops searches when executed within txp:(
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
Re: htaccess suggestions
Schucks. Hmm.
If you remove the ?$ so that you get RewriteCond %{QUERY_STRING} m\=any(&q\=1)? [NC]
you should at least be able to conduct searches and will catch ?m=any
, ?m=any&q=1
but not ?m=any&q=
i.e. a search with no query string. If that also interrupts txp’s search function, I wonder if something else is at play…
TXP Builders – finely-crafted code, design and txp
Offline
Re: htaccess suggestions
no:)
Thanks for all this Julian, It’s a real hair puller.
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
#16 2014-08-19 16:58:12
- GugUser
- Member
- From: Quito (Ecuador)
- Registered: 2007-12-16
- Posts: 1,473
Re: htaccess suggestions
colak wrote #283059:
(…) It’s a real hair puller.
Or hair-raising.
;-)
Last edited by GugUser (2014-08-19 17:01:44)
Offline
Re: htaccess suggestions
Based on Pete’s reply, what about this?
RewriteCond %{QUERY_STRING} m=any&q=1 [OR]
RewriteCond %{QUERY_STRING} m=any&q= [OR]
RewriteCond %{QUERY_STRING} m=any [NC]
RewriteRule ^ - [F]
I’ve added the [OR]
flag and removed the (unnecesary?) escaping \
Maybe this shorter version could work too:
RewriteCond %{QUERY_STRING} m=any(&q=1?)? [NC]
RewriteRule ^ - [F]
Offline
Re: htaccess suggestions
Both of the above return the same errors as all previous ones. ie they prevent searches from within txp by generating a 403.
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
Re: htaccess suggestions
Here’s a couple of solutions which semi work:)
<files /?m=any&q=|/?m=any=|/index.php?s=|/?m=any&q=1|>
order allow,deny
deny from all
</files>
and
<FilesMatch /?m=any&q=|/?m=any=|/index.php?s=|/?m=any&q=1|>
order allow,deny
deny from all
</FilesMatch>
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline