Does anyone know if there is a way to change it so page layouts are stored in the page using a relative url currently we have:

<mso:PublishingPageLayout msdt:dt="string">http://mydomain.com/sites/Psoriasis/_catalogs/masterpage/Custom_Layouts/PW_layout2.aspx, PW_layout2</mso:PublishingPageLayout>

and we want:

<mso:PublishingPageLayout msdt:dt="string">/_catalogs/masterpage/Custom_Layouts/PW_layout2.aspx, PW_layout2</mso:PublishingPageLayout>

this is so we can easily move the site to another web application via wsp at a later date

  • Try some of the solutions on this similar SO answer: stackoverflow.com/questions/1634449/… Note the accepted one seems to not be the correct one :) – John-M Dec 9 '14 at 16:18
  • problem is when you select a page layout for a page, it puts the absolute url into the page aspx file rather than relative - I know I could change it manually after, but that isn't ideal as new pages could be created all the time and then when the site is moved it wont work anymore – Jason Dec 10 '14 at 9:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.