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

Forums / Designing & Styling / Changing Page Template Issue

Changing Page Template Issue

8 posts, 0 answered
  1. Chris
    Chris avatar
    8 posts
    Registered:
    05 Dec 2008
    14 Apr 2011
    Link to this post
    Have a page with a template called "Resources" and there are content blocks with text within that page. The Resources template was based on a base template called "Subpage".

    I created a new template called "News" based on "Subpage" just like Resources was based off of.

    When I change the template on my page from Resources to News, I lose all the content blocks. They are simply gone like it's a brand new page. The page is not renamed or anything, just moved to Draft status with no content.

    Is this correct?

    I have hundreds of pages to change templates on.

    Anybody have a suggestion on how best to change templates on hundreds of pages without having to rebuild each page?

    Thanks in advance.
  2. Boyan Barnev
    Boyan Barnev avatar
    1429 posts
    Registered:
    02 Dec 2016
    15 Apr 2011
    Link to this post
    Hi Chris,

    I'm sorry to hear about issues you've been experiencing regarding this functionality. This is happening because the widgets get associated with the placeholders on the template, and once you change the template the widgets "don't know" to which placeholder to associate, that's why they just become orphaned and don't get displayed. I agree with you that this behavior might be unexpected and cause problems, and we are discussing how we can improve this. Any suggestions are welcome. In the meantime, Lyubomir Dokov provided a sample code which offers a solution to the problem. You can track his reply and get hte code sample on this forum thread. Please take a look at it and try the proposed solution.
    I hope you find this information useful. If you need any further help, please do not hesitate to write back.

    Regards,
    Boyan Barnev
    the Telerik team

  3. Steve
    Steve avatar
    3037 posts
    Registered:
    03 Dec 2008
    15 Apr 2011
    Link to this post
    What if you just disallowed deleting\changing of templates if there are child pages who's content WILL become orphaned....?

    Or at least start version the templates so when I have someone BREAK a template I can roll it back
  4. Boyan Barnev
    Boyan Barnev avatar
    1429 posts
    Registered:
    02 Dec 2016
    18 Apr 2011
    Link to this post
    Hello Steve,

    Thanks for the suggestion, as I mentioned in my previous reply, customer feedback is very important, so it will be taken into consideration. We already have implemented warning messages that do not allow deletion of templates who have pages based on them, so a similar warning when changing a template is a possible  option.

    Regards,
    Boyan Barnev
    the Telerik team

  5. Chris
    Chris avatar
    8 posts
    Registered:
    05 Dec 2008
    18 Apr 2011
    Link to this post
    Thanks for the response to this post. It is appreciated. We will try to code that you've provided and see what happens.

    I will say for the record as a Sitefinity partner that not being able to change templates on a page within in a quality CMS like Sitefinity is a fairly large miss. Changing templates freely is exactly the point of having a CMS. As a technical company, we will be able to work around this, but as we hand our sites off to our clients to manage on their own, it poses a large risk for them and exposure for us to not have this feature in place.

    I'm not proposing a warning pop up as much as I am a fix. Please add this to your road map asap. We'll speak with our partner contact at Sitefinity to make sure our request is formally submitted.

    In the meantime, I will say that we couldn't live without this forum. Your responsiveness and quality of responses has been a big help to us over the years. Thanks for that.
  6. Boyan Barnev
    Boyan Barnev avatar
    1429 posts
    Registered:
    02 Dec 2016
    19 Apr 2011
    Link to this post
    Hi Chris,

    Thank you for the understanding and  the constructive feedback. Please be assured that we have our attention focused on this problem and we will be working on its resolution. 

    Best wishes,
    Boyan Barnev
    the Telerik team

  7. Dan Sorensen
    Dan Sorensen avatar
    256 posts
    Registered:
    13 Aug 2010
    30 Jul 2011
    Link to this post
    What is the current status of this issue? I am running 4.1 SP3.

    Is there a recommended work-around? Can I create a different template as long as I use the same class names for the target regions?

    I need to be able to switch templates as well. We retain the same base template with common header/footer, but will switch between 1, 2, and 3 column pages depending on the current content needs.
  8. Boyan Barnev
    Boyan Barnev avatar
    1429 posts
    Registered:
    02 Dec 2016
    01 Aug 2011
    Link to this post
    Hello Dan Sorensen,

    Currently there should be no problems implementing the described scenarios - witht he changes we have introduced, now when a template is changes, if the controls do not have a specified placeholder on the new template, they will either be automatically placed in the first available content placeholder, or appear as semi-transparent, indicating that they need to be placed in a valid placeholder in order to be displayed on the frontend.

    Best wishes,
    Boyan Barnev
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
8 posts, 0 answered