How to add an exception to this rewrite rule
Posted
by
codecowboy
on Pro Webmasters
See other posts from Pro Webmasters
or by codecowboy
Published on 2010-11-02T14:31:20Z
Indexed on
2011/02/24
7:32 UTC
Read the original article
Hit count: 288
apache
|url-rewriting
Hi,
I need to change this so that one file in wp-admin is not forced through https:
# add a trailing slash to /wp-admin
RewriteCond %{REQUEST_URI} ^.*/wp-admin$
RewriteRule ^(.+)$ https://%{SERVER_NAME}/$1/ [R=301,L]
This forces all requests to /wp-admin through SSL but it is breaking a wordpress plugin which needs to access wp-admin/admin-ajax.php.
Is there a way to adjust the rule so that it will allow non encrypted requests to that one file?
thanks!
© Pro Webmasters or respective owner