Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Jun 21, 2011 @ 17:45
    Jeroen Breuer
    0

    General pages with multiple websites

    Hello,

    I've got multiple websites in 1 Umbraco installation. Each website has it's own nodes and content, but now the customer wants to have some general pages that apply to all the websites. What's the best way to do this? I can create a General topnode outside of all the websites and store the content in there, but how can I use those pages on all the websites? Perhaps select them with the Multi Node Tree Picker, but how will that go for the url's? Any good ideas?

    Jeroen

  • Ismail Mayat 4511 posts 10092 karma points MVP 2x admin c-trib
    Jun 21, 2011 @ 18:10
    Ismail Mayat
    1

    Jeroen,

    In the past I have done it exactly in that way however the section that contains those pages have been hidden using umbracoNaviHide property and I have created a separate doc type for that reusable content and excluded it from any sitemaps , navigation and search indexes. So basically its there and published but you cannot see if from the front end.

    If you have 3 sites each one needs to use this reusable page for arguments sake its the disclaimer page. You create that in the reusable area.  Create 3 disclaimer pages in your sites and link to the disclaimer page in reusuable area (you could even you relations then your look up will be quicker).  In your page template before writing out content check you have a linked page, if you have it then get content from there if not then display content in current page.

    Regards

     

    Ismail

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Jun 21, 2011 @ 18:12
    Jeroen Breuer
    0

    Hi Ismail,

    That's a nice suggestion :). The only problem is I still need to create the pages on all the website and I prefer not to do that.

    Jeroen

  • Ismail Mayat 4511 posts 10092 karma points MVP 2x admin c-trib
    Jun 21, 2011 @ 18:25
    Ismail Mayat
    0

    yes they are however just empty stub placeholder pages i cant think of another way todo it, unless maybe you add alternate urls in the magic alternate url field for that shared content not sure if that has any seo implications.

    Regards

    Ismail

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Jan 12, 2012 @ 17:25
    Jeroen Breuer
    0

    Anyone else might have another solution for this?

    Jeroen

  • Dan Diplo 1554 posts 6205 karma points MVP 6x c-trib
    Jan 12, 2012 @ 18:03
    Dan Diplo
    0

    Do you know about the "special" umbracoInternalRedirectId property?

    "Add the umbracoInternalRedirectId property alias to your document type with a content picker and Umbraco will load the selected page’s content transparently; no url redirection"

    So you could have section outside of your main websites for all shared content. Then create pages within the website with the above property with a Content Picker datatype. Then the user can select one of the general pages and have the content seemlessly displayed within the main website.

     

  • Jeroen Breuer 4908 posts 12265 karma points MVP 5x admin c-trib
    Jan 12, 2012 @ 18:12
    Jeroen Breuer
    0

    That won't work because the content needs to "copied" to other nodes without selecting it. So I create a node in 1 language and it needs to be available in the other languages without using a content picker. It somehow needs to be done automatically.

    Jeroen

  • Stephen 767 posts 2273 karma points c-trib
    Jan 12, 2012 @ 19:34
    Stephen
    0

    Interesting. What about this:

    - you create an extra root node to contain all common pages
    - you link those pages into each site using content pickers or multi-nodes tree pickers

    Then a normal page say /en/about-us would link to /common/whatever.

    If you want the url to be /en/whatever then you need to a) use your own custom NiceUrl to replace "common" by "en" and b) use some rewriting to replace "en" back to "common".

    But if you want the "whatever" to change depending on sites... then I don"t see how you can do it without creating nodes in each sites, maybe using the umbracoInternalRedirectId trick to avoid duplicating content.

    ?

  • Dan Diplo 1554 posts 6205 karma points MVP 6x c-trib
    Jan 12, 2012 @ 20:35
    Dan Diplo
    0

    @Jerouen - "That won't work because the content needs to "copied" to other nodes without selecting it."

    So do that in an event handler that hooks into the publish event? In the handler create a new page (using the Document API) that has the umbracoInternalRedirectId  property point back to the id of the page being published.  If there's a logical connection between the two pages (which there has to be if you want it to be automatic) then that would work, and the content in the "child" page would always mirror the content in the "parent" page.


Please Sign in or register to post replies

Write your reply to:

Draft