Assets re-direct to https
I am having an issue where cached pages seem to be served with image assets pointing to https rather than http. Since I do not have a signed certificate, this causes images not to display at all to users that are not logged in. Clearing the cache temporarily fixes the issue, but it always seems to re-appear.
Any thoughts about what might be going on?
I will note that I do not have this problem on my staging server, just on production. The FUEL files are the same in the two environments. So, I suspect it is really a problem with FUEL interacting with the PHP/Apache config on the production server.
The source that FUEL outputs really is <img ... src="/assets/images/foo.png">. So I am a bit mystified why this is interpreted as an HTTPS reference. The links to stylesheets have the same structure but are interpreted correctly.
It seems that the reason relative links are interpreted as HTTPS links is because the page header defines a BASE element with https in the URI.
I'm curious about how that goes bad, though. The <base> element read:
<base href="<?php echo site_url()?>" />
Was the header block being saved in the cache with an https site_url() and then served up?