redirect whole site to HTTPS When I include the snippet found in answer to this question How to simply make the whole site HTTPS?  to redirect to https in my htaccess.php file, all urls resove to /index instead of going to the page originally requested (Ex: user tries to access example.com/about, and is redirected to https://example.com).  

Here is the snippet I used:

RewriteCond %{HTTPS} off
RewriteCond %{HTTP:X-Forwarded-Proto} !https
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]


I have also tried the slight variation found at https://www.drupal.org/https-information, which has the same unsatisfactory result:

RewriteCond %{HTTPS} off [OR]
RewriteCond %{HTTP_HOST} ^www.domainname\.com*
RewriteRule ^(.*)$ https://domainname.com/$1 [L,R=301]


How can I make the site all https without breaking the ability to navigate to a specific page? 

Edited to add: I've got the Secure Pages module, but haven't managed to get it to work. If you have advice on that point instead I'd happily take it.
RewriteCond %{HTTPS} !=on
# This checks to make sure the connection is not already HTTPS

RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]
# This rule will redirect users from their original location, to the same location but using HTTPS.