WordPress behind Proxy – Mixed Content

My Server Env for a wordpress site is as follows:

----------               ---------              -------------
| Client | <-- HTTPS --> | Proxy | <-- HTTP --> | WordPress |
----------               ---------              -------------

The Problem is that the WordPress Site itself is served internally over HTTP but the Client communicates over HTTPS with the Proxy. Since WordPress is configured with HTTP it returns links and images-src with “http://” which leads to mixed-content errors in the browsers. (Eg. all css / script links generated by wp_head() return http:// urls)

Can i configure WordPress to generate only “https://” urls, even if it’s serverd over HTTP?

WordPress runs on nginx webserver
The Proxy is also nginx

2 Answers
2

Please take a look at Administation Over SSL, particularly the “Using a Reverse Proxy” section.

Leave a Comment