diff options
author | Mario Vavti <mario@mariovavti.com> | 2015-12-07 00:01:03 +0100 |
---|---|---|
committer | Mario Vavti <mario@mariovavti.com> | 2015-12-07 00:01:03 +0100 |
commit | c8c9916b5977e3ae8db4762209ca4bf99a3058ee (patch) | |
tree | eb8b5c906054a85a6120aff623ae19941f849f88 /include/plugin.php | |
parent | 5490919557362176ae50005f3f205505c21cbe23 (diff) | |
parent | 3f920da4137ecb91b3aeb2683f2e2b59b4d088cc (diff) | |
download | volse-hubzilla-c8c9916b5977e3ae8db4762209ca4bf99a3058ee.tar.gz volse-hubzilla-c8c9916b5977e3ae8db4762209ca4bf99a3058ee.tar.bz2 volse-hubzilla-c8c9916b5977e3ae8db4762209ca4bf99a3058ee.zip |
Merge branch 'master' of https://github.com/redmatrix/hubzilla
Diffstat (limited to 'include/plugin.php')
-rwxr-xr-x | include/plugin.php | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/plugin.php b/include/plugin.php index 1d4caac0f..1f4d60736 100755 --- a/include/plugin.php +++ b/include/plugin.php @@ -495,6 +495,15 @@ function format_css_if_exists($source) { return '<link rel="stylesheet" href="' . script_path() . '/' . $path . '" type="text/css" media="' . $source[1] . '">' . "\r\n"; } +/* + * This basically calculates the baseurl. We have other functions to do that, but + * there was an issue with script paths and mixed-content whose details are arcane + * and perhaps lost in the message archives. The short answer is that we're ignoring + * the URL which we are "supposed" to use, and generating script paths relative to + * the URL which we are currently using; in order to ensure they are found and aren't + * blocked due to mixed content issues. + */ + function script_path() { if(x($_SERVER,'HTTPS') && $_SERVER['HTTPS']) $scheme = 'https'; |