Equivalent of Apache's SetEnv Variable
Michael Shadle
mike503 at gmail.com
Wed Aug 4 03:34:56 MSD 2010
yeah, var_dump($_SERVER) - should show you normal variables.
Do you see $_SERVER['HTTPS']?
I think the key location you're missing is putting it in here:
location ~ \.php$ { ## Execute PHP scripts
expires off; ## Do not cache dynamic content
fastcgi_param HTTPS $fastcgi_https;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_script_name;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi_params; ## See /etc/nginx/fastcgi_params
try adding these?
fastcgi_param MAGE_RUN_CODE base;
fastcgi_param MAGE_RUN_TYPE website;
}
FYI, I was not aware of an $fastcgi_https variable. If there is one,
that is awesome and I need to add that to my fastcgi_params - it
should be default as most apps seem to rely on $_SERVER['HTTPS']
I am going to go look if it exists or not :)
On Tue, Aug 3, 2010 at 4:11 PM, Raina Gustafson <raina at thequeensmen.com> wrote:
> Ok. That's really helpful information. Right now, both of these output nothing:
> <?php echo $_SERVER['MAGE_RUN_CODE']; ?>
> <?php echo $_SERVER['MAGE_RUN_TYPE']; ?>
More information about the nginx
mailing list