+1-888-365-2779
Try Now
More in this section

Forums / Bugs & Issues / Cannot add content to a ContentPlaceHolder

Cannot add content to a ContentPlaceHolder

4 posts, 0 answered
  1. bnye
    bnye avatar
    332 posts
    Registered:
    22 Sep 2005
    16 Nov 2007
    Link to this post
    Has anyone else noticed since 3.1 you can no longer add content to a ContentPlaceHolder on the page after you have added content to the same ContentPlaceHoder on the template. The CPHs are grayed out. Is this by design?

    Sincerely,

    Ben
  2. Bob
    Bob avatar
    330 posts
    Registered:
    24 Sep 2012
    19 Nov 2007
    Link to this post
    Hello Ben,

    This is by design. There are two reasons for that decision. First, enabling the place holder but disallowing the controls from the templates within it complicates very much JavaScript and CSS. Second, it seems logical to be that way, like nested master pages in VS.

    However, you are still able to add controls to such placeholder but in classic view mode or thorough the toolbox and Add button.

    Sincerely yours,
    Bob
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. bnye
    bnye avatar
    332 posts
    Registered:
    22 Sep 2005
    20 Nov 2007
    Link to this post
    Bob -

    I'll buy that.

    However, if I have use a template wide control like breadcrums or pagetitle, based on that logic I would have to create a separate CPH for the main page content or simply abandon the "Overlay" designer (which I like very much).

    I do see what you mean though about VS nested master pages. Perhaps I am using the templates in an unorthodox way. Perhaps a better way would be to create a nested template that is added to the CPH of another template after the template wide controls are added. Is there a way to nest templates like that through the template editor? I hope that makes sense.

    Sincerely,

    Ben


    Ben
  4. Tihomir
    Tihomir avatar
    53 posts
    Registered:
    24 Sep 2012
    23 Nov 2007
    Link to this post
    Hello Ben,

    Unfortunately, currently we do not support adding nested templates natively through our admin. A work-around to the problem will be to create the nested master pages in VS and then just upload them to Sitefinity as templates. This is how you will achieve the same functionality although with a bit more work. Here is a hint on how to nest a master page - just refer to the outer master page in the code of the page which will be nested inside it:
    <%@ Master Language="C#" AutoEventWireup="true" MasterPageFile="MasterPage1.master" %> 

    Hope this helps!

    If you have more questions, don't hesitate to ask!

    Kind regards,
    Tihomir
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
Register for webinar
4 posts, 0 answered