My htacces file has the following command in it forcing a web site to SSL.
RewriteEngine On
RewriteCond %{SERVER_PORT} 80
RewriteRule ^(.*)$ https://www.domain.com/$1 [R=301,L]
However the problem I have is that on my local MAMP server, if I go to localhost.domain.com in the browser I get redirected to domain.com.
Is there any conditional logic I can use in htaccess to say "if the request is from localhost then dont force redirect to ssl on the main domain"