1

I have a Multi-Site installation of Wordpress, with multiple subdomains, but only one of the subdomains has an SSL certificate.

The domains are such:

www.example.com
blog1.example.com
blog2.example.com

secure.example.com

secure.example.com is the subdomain which has a SSL cert installed.

If someone types in blog1.example.com/wp-admin/dashboard.php, how can I force them to secure.example.com/wp-admin and then after they log in redirect them back to blog1.example.com/wp-admin/dashboard.php?

1
+50

I would recommend using Peters Login Redirect to redirect users after login I have used it before and works well.

You could redirect users to the secure area by adding the below to your .htaccess file :

Redirect 301 blog1.example.com/wp-admin/dashboard.php secure.example.com/wp-admin 
  • you might be headed in the right direction with this. – cwd Sep 4 '11 at 13:02
0

I would get a wildcard SSL certificate. It allows an unlimited number of subdomains to be secured for your main domain.

Then I would force SSL login in wp-config.php:

define('FORCE_SSL_LOGIN', true);
/* That's all, stop editing! Happy blogging. */
require_once(ABSPATH . 'wp-settings.php');

Administration Over SSL

  • thanks but not looking to go the wildcard ssl route. – cwd Sep 4 '11 at 12:55
  • May I ask why not? Seems like that would be the quickest and simplest solution for your problem. – 128KB Sep 5 '11 at 22:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.