I have an SSL through Cloudflare and it only works on my main site, and not the wordpress part.
regular site:
http://championsdrivingschools.com
wordpress
http://championsdrivingschools.com/checkout/
If I do force SSL on the site it makes the wordpress look all it style and everything and it looks just like text
If you have added static URL in the pages without https then Url will not show green sign in the browser. please check static URL of any static assets and set below setting to make all pages with https.
Step 1: In your WordPress administrator dashboard, go to Settings -> General and change both URLs to have https:// rather than http://.
Step 2: These site asset files can easily be corrected by fixing the rewrite rules in your .htaccess file found at the root of your WordPress application.
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{SERVER_PORT} !^443$
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
To get started, head to WooCommerce > Settings.
Related
I am encountering a problem with my wordpress page. I am using the sporty theme and have setup the page. Now I would like to activate SSL.
What have I done:
I changed
siteurl and home in the wp-options table
I used the DB Migrate plugin to modify all links.
I set up my htaccess file like this
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{ENV:HTTPS} !=on
RewriteRule ^.*$ https://%{SERVER_NAME}%{REQUEST_URI} [R,L]
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
I am still stuck with a redirect to the base url which start with http. Even if I remove the htaccess this happens, so i doubt the htaccess is the problem.
I also tried adding
define('WP_HOME','https://tc-eislingen.de');
define('WP_SITEURL','https://tc-eislingen.de');
to the wp-config.php but the nasty redirect to http stays.
Is there a redirect in the template I am missing?
Update
Why the downvote? I followed all the rules? Is there anything wrong why my quesiton?
you shouldn't be changing .htaccess file code for it. Just change the urls in database and install
Really Simple SSL
and activate necessary settings in it. You must change http: url you placed manually into https though.
My blog https://sonicscoop.com has older posts dating all the way back to 2012 with hundreds of Facebook "likes" such as this one https://sonicscoop.com/2012/08/29/the-big-list-of-free-pro-tools-plugins-2/, but they all lost their correct count when we switched to https: as you can see here:
https://developers.facebook.com/tools/debug/sharing/?q=https%3A%2F%2Fsonicscoop.com%2F2012%2F08%2F29%2Fthe-big-list-of-free-pro-tools-plugins-2%2F
For some reason Facebook's debugger is detecting the canonical and og:url as https:// even though the page's rendered HTML shows them as http://.
If I can get Facebook to pick up the http canonical for older posts I'm hoping the likes will return to the correct count. Here is my .htaccess file:
# --enable htaccess rewrites
RewriteEngine on
# --force https
RewriteCond %{HTTPS} off
RewriteRule ^ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L,NE]
# --remove www for site
RewriteCond %{HTTP_HOST} ^www\.sonicscoop\.com [NC]
RewriteRule ^(.*)$ https://sonicscoop.com/$1 [L,R=301]
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
AddHandler application/x-httpd-php54s .php
Try below solution
1) WordPress Dashboard
2) After moving your site files (if necessary), log into your your WordPress Dashboard as an administrator.
Next, click on Settings from the menu, and then General.
3) Click on General to get started.
4) The two fields we'll change are WordPress Address (URL) and Site Address (URL) set https for both url
5) Scroll down the page and click on the Save Changes button.
6) After that Settings > Permalinks
7) Scroll down if needed and click "Save Changes".
after above all steps check og:url then check if FB like is working for you.
When facebook crawl your page it got redirected to https version of your page. Even if your og:url use http version, I think facebook will still use the canonical or final url of your page.
Try to change your rewrite condition on .htaccess into something like:
RewriteEngine on
RewriteCond %{HTTPS} off
RewriteCond %{HTTP_USER_AGENT} !facebookexternalhit/[0-9]
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L,NE]
# --remove www for site
RewriteCond %{HTTP_HOST} ^www\.sonicscoop\.com [NC]
RewriteRule ^(.*)$ https://sonicscoop.com/$1 [L,R=301]
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
AddHandler application/x-httpd-php54s .php
You can use Really simple SSL plugin if it is wordpress site.
Install plugin and activate.
Go to settings you can see SSL. CLICK on it.
enable ssl.
This plugin will take all ssl issues.
I have a serious problem with the links when using https. My knowledge with using https is poor. Although following are the processes that i've done so far.
Scenario:
I have a site that uses HTTPS. ( Certified )
I need only one CheckOut page to load in https where the checkout page is related to sub-domain. ex. member.mydomain.com
Site is in WordPress
Not using WooCommerce !!
Results:
Using htaccess i managed to redirect that certain page ie. Checkout page in https and it works.
ex. https://member.mydomain.com/checkout
However, The Problem:
The problem is that all links are dead links in the checkout page due to which it messes up the whole site. The CSS, JS files all are being loaded in https.
What i have tried so far !!
I tried updating the general settings url to https. So, it works but the same issue to all pages. All the links are broken.
Followed the instructions on this post https://wordpress.stackexchange.com/questions/75921/ssl-breaks-wordpress-css
Also, in this https://managewp.com/wordpress-ssl-settings-and-how-to-resolve-mixed-content-warnings
But the above did not seem to do the trick. I still have the broken links. What am i missing here? Please suggest.
Thank you
Found the solution finally.. Tried modifying the htaccess file again.
Following is what i added in my htaccess in order to fix the problem. It might be useful to someone in the future.
<IfModule mod_rewrite.c>
#-------------------SUB.DOMAIN.COM---------------------
RewriteCond %{HTTP_HOST} ^subdomain.domain.com
RewriteCond %{DOCUMENT_ROOT}/members%{REQUEST_URI} -f
RewriteRule . %{DOCUMENT_ROOT}/members%{REQUEST_URI} [L]
RewriteCond %{HTTP_HOST} ^ subdomain.domain.com
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule . subdirectory/index.php [L]
#-----------------SUB.DOMAIN.COM---------------------
</IfModule>
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
This solved the subdomain issue and the 500 error requests as well as the broken links problem.
This is a WordPress site.
Originally the person who built the site had set it up so that the site gets pulled up by going to domain.com. So all requests for www.domain.com gets punted to domain.com.
This is the standard code inside my .htaccess file:
# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
# END WordPress
How can I change my .htaccess file so that this forward does NOT happen and folks can get to the site using BOTH domain.com as well as www.domain.com...??
Looks like WordPress itself determines which version will show up. The WordPress Address field in Settings is what sets the tone. There is no easy way to make both non-www and www work. Can be done via .htaccess I suppose but definitely not worth the effort.
In general option in wordpress, I have changed the wordpress directory to be on http://mywebsite.com but wordpress dashboard is still in htpps causing mixed content warning and images in dashboard are not displayed even after disabling mixed content filter on firefox.
I this is my .htaccess file
Options +FollowSymlinks
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{SERVER_PORT} ^443$
RewriteRule ^(.*)$ http://%{HTTP_HOST}/$1 [R=301,L]
# BEGIN WordPress
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
# END WordPress
</IfModule>
What is the possible solution to overcome this problem.
There is a setting in your wp-config.php file that directs all admin traffic over https. You would need to disable that option for your admin panel to work correctly.
FORCE_SSL_ADMIN needs to be false:
define('FORCE_SSL_ADMIN', false);
solves the issue. See relevant WordPress Codex pages:
http://codex.wordpress.org/Administration_Over_SSL
http://codex.wordpress.org/Function_Reference/force_ssl_admin