If we have https, use https
authorMichael J. Rubinsky <mrubinsk@horde.org>
Sun, 15 Feb 2009 20:40:08 +0000 (15:40 -0500)
committerMichael J. Rubinsky <mrubinsk@horde.org>
Sun, 15 Feb 2009 20:40:08 +0000 (15:40 -0500)
framework/Service_Facebook/lib/Horde/Service/Facebook.php

index 16de1bb..20f227f 100644 (file)
@@ -301,7 +301,7 @@ class Horde_Service_Facebook
      */
     public static function get_facebook_url($subdomain = 'www')
     {
-        return 'http://' . $subdomain . '.facebook.com';
+        return (!empty($_SERVER['HTTPS']) ? 'https://' : 'http://') . $subdomain . '.facebook.com';
     }
 
     /**