Skip to main content
Topic: Problem with HTTPS detection on Azure WebApps (Read 1691 times) previous topic - next topic

Problem with HTTPS detection on Azure WebApps

When I try to deploy on a Azure WebApp and I force HTTPS, the base URL (in config.php) is set not correctly to a HTTPS URL.
It stays on HTTP causing a lot of mixed content errors.

It should be better that all referenced links are relative and not fully qualified or the code for detecting HTTPS should be checked.

Re: Problem with HTTPS detection on Azure WebApps

Reply #1
@xvisionbelgium‍ ‍lines 20 and 21 in config.php contain the following,
Code: [Select]
// Can Be Set Manually Like "http://localhost/mysite/".
define("SITE_ADDR", $site_addr);
which should work fine in any environment. please confirm that the mixed content error you are getting is not with a resource you added yourself to phprad. Setting this
Code: [Select]
define("SITE_ADDR", $site_addr);
on line 20 to this
Code: [Select]
define("SITE_ADDR", "https://localhost/mysite/");
should fix it. Please replace https://localhost/mysite/ with your own site link, make sure to include the https:// to it. Note that if the issue you are having is with images, then it means you might have configured phprad to store the image full path in the database, instead of the relative path.