Page 1 of 1

content_image tag ignores https in generated url

Posted: Mon May 22, 2017 11:39 am
by d4creative
I am using {content_image} to load a background image ('urlonly') for a div in the page template. For pages that are designated to use https the image url that is generated by the tag uses http protocol, causing a security error for browsers with more locked-down security settings (i.e. my client who owns this website).

Any thoughts on why this is happening or how to fix it?

Re: content_image tag ignores https in generated url

Posted: Thu May 25, 2017 2:20 pm
by DIGI3
I can't recreate this issue in 2.1.6, but I also tested in 2.2 and the generated urls are protocol-less.

A short term fix if you can't find out why it's doing it is to use the |replace modifier, e.g. {$myimage|replace:'http':'https'}

You should also check your config file and htaccess to make sure nothing is going on that would cause the url to be generated incorrectly.

Re: content_image tag ignores https in generated url

Posted: Thu May 25, 2017 3:16 pm
by Rolf
Config.php and .htaccess settings for SSL described in:
https://www.cmscanbesimple.org/blog/set ... ade-simple