#1 May 4, 2017 5:04am

Plork
Member
Registered: May 4, 2017
Posts: 1

Changing the hostname

Hi,

We need to change the host name of our site (http -> https). Looking through the database it seems quite a lot of the links (mostly <img src=..>)  in bigtree_pages have been embedded with the full path.

Is there an easy way to update these links automatically or will they need updating manually one by one?

Thanks

Offline

#2 May 4, 2017 9:23am

timbuckingham
Administrator
From: Baltimore, MD
Registered: April 2, 2012
Posts: 974

Re: Changing the hostname

Generally links back to the site should either be encoded as {staticroot} or {wwwroot} which will update with your configuration file. I've run into some sites where for whatever reason they didn't and in those cases I'd advise replacing the web root with {staticroot} for any image references directly in the DB (or re-saving the page *should* do it).

For references to outside URLs you pretty much have to either change everything in the database or run $cms->makeSecure(); on all your templates. That will cause the site output to be fed through an output buffer filter that rewrites http:// src references to https:// (but it's a small performance hit).

Offline

Board footer

Powered by FluxBB

The Discussion Forum is not available on displays of this size.