views:

103

answers:

1
+3  A: 

The problem is that the urls in the links and image src are absolute rather than relative.

http://subdomain.domain.com/someimage.gif is always going to use http as its an absolute link.

/someimage.gif is a relative link (the leading / means relative from the hostname) so if this url is from a http site it will use http, from a https site will use https (well technically depends upon the document BASE but you can ignore that for your purposes)

E.g. given the relative URL /somepage/someimage.gif

When accessed from this page   => Will mean this
------------------------------------------------
http://domain.com/somepage/    => http://domain.com/somepage/someimage.gif
httpS://domain.com/somepage/   => httpS://domain.com/somepage/someimage.gif
http://NEWDOMAIN.com/somepage/ => http://NEWDOMAIN.com/somepage/someimage.gif

and everything will work just fine with no warnings.

The built in CEWP puts all links in as Absolute. To fix -

MSDN - Fixing absolute URLs for all Alternate Access Mappings (AAM) of Content Editor Web Part with a Control Adapter

Ryan
Luckily I'm not a content creator (I would shoot myself in the face), but rather a support-tech type person. You are correct that when our site admins place images, they use the Content Editor Web Part, which sharepoint inputs the URL as an absolute. This is annoying as ****. I don't suppose there is any way to tell SharePoint to use Relative urls only, eh? Sigh... I guess it's time for another quick training session. :(
Kolten
Hmm - I thought the CEWP change things to relative automatically - but it doesn't <head slap for MS> - update on the way.
Ryan
Wow such a headache to implement. I don't understand it all, but looks like it would do the job with my limited knowledge of the subject.
Kolten