title: Redirect One Domain To https 2nd Domain http
body: <p>We have a domain where every page is set to https in .htaccess.
  There is also a 2nd domain for the Irish version of the site, where we don't have a certificate, so we need the pages to be set to http.
  We also want to ensure both domains are set to www.
  To further complicate the matter, users can login to part of the site, and we want those pages to be secure. What we plan is to detect the Irish domain and login page and redirect to the main domain.</p>
  
  <p>I can code individual parts of this in .htaccess, but I am not sure how to code the whole scenario without it getting horribly complicated, messy and difficult to debug. I also don't want to double redirect pages unnecessarily.</p>
  
  <p>So in summary:</p>
  
  <pre><code>(www.)example.com -&gt; https://www.example.com
  (www.)example.ie -&gt; http://www.example.ie
  (www.)example.ie/login.php -&gt; https://www.example.com/login.php
  </code></pre>
  
  <p>I would be grateful for any help, haven't been able to find any similar scenarios.  Thanks.</p>