82 | | $this->url = $b->blog_url; |
| 82 | |
| 83 | /** |
| 84 | The host server might support SSL/TLS encryption, but using |
| 85 | it might not be mandatory, i.e. you have a self-signed certificates. |
| 86 | |
| 87 | Thus, here, we check whether the client is using SSL/TLS or not, |
| 88 | and we set the default url so that every call to the getQmarkURL |
| 89 | function will return the good url (think about plugins for example). |
| 90 | */ |
| 91 | if (!empty ($_SERVER['HTTPS'])) |
| 92 | $this->url = str_replace ('http://', 'https://', $b->blog_url); |
| 93 | else |
| 94 | $this->url = $b->blog_url; |
| 95 | |