所有的鸟儿他们都知道, 他们的巢应该筑在什么地方, 鸟儿知道自己该在什么地方筑巢, 那就意味着他们了解他们自己的使命。 我们身为万物之灵的人类, 怎么会不知道,连鸟儿都知道的道理呢?
nginx proxy_set_header $_SERVER["HTTPS"]
nginx proxy_set_header $_SERVER["HTTPS"]

nginx proxy_set_header $_SERVER["HTTPS"]

with a little digging thru $_SERVER vars, it appears that nginx config of

proxy_set_header HTTPS on;

does NOT set

$_SERVER[‘HTTP’]=on

, but rather, prepends the meta key (for all proxy_set_header vars?) with "HTTP_", so that,

$_SERVER[‘HTTP_HTTPS’]=on

as I thinkg abt it, as the apache server itself is NOT serving https://, HTTPS=on would be, technically, incorrect in this scenario.

in any case, editing in,

advagg_js_cdn/advagg_js_cdn.module

– $schema = ((isset($_SERVER[‘HTTPS’]) && $_SERVER[‘HTTPS’] == ‘on’) || (isset($_SERVER[‘HTTP_X_FORWARDED_PROTO’]) && $_SERVER[‘HTTP_X_FORWARDED_PROTO’] == ‘https’)) ? ‘https’ : ‘http’;

+ $schema = ((isset($_SERVER[‘HTTPS’]) && $_SERVER[‘HTTPS’] == ‘on’) || (isset($_SERVER[‘HTTP_X_FORWARDED_PROTO’]) && $_SERVER[‘HTTP_X_FORWARDED_PROTO’ || (isset($_SERVER[‘HTTP_HTTPS’]) && $_SERVER[‘HTTP_HTTPS’] == ‘on’)] == ‘https’)) ? ‘https’ : ‘http’;

results, correctly, in,

script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"
^^^^^

 http://drupal.org/node/1072812

发表回复

您的电子邮箱地址不会被公开。 必填项已用*标注