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

Forums / General Discussions / Template Contents and Templates from Templates

Template Contents and Templates from Templates

10 posts, 0 answered
  1. Todd Stanistreet
    Todd Stanistreet avatar
    4 posts
    Registered:
    19 Mar 2010
    13 May 2010
    Link to this post

    I created a template off of a master page. The template has a single main content area and 2 content areas for the purpose of placing an image or caption that will be the same for most pages.

    I created a second template off the first template and dropped the appropriate image and caption in the 2 content areas. I expect that my site might have 2 or 3 templates created off the first with a different image and/or caption.

    This appears to work but when I create a page from the second template, anything added to a content area in the second or the first template does not appear in the page. In other words, the ability to add content to the content areas within a template doesn't seem to actually do anything. It doesn't require 2 templates to cause this issue.

    Additionally 4 of my 6 test pages (which all use the 2nd template) get the following error during preview:

    ------------------------------------

    ScriptManager object is not set to a reference.
    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.Web.HttpException: ScriptManager object is not set to a reference.

    Source Error:
    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


    Stack Trace:

    [HttpException (0x80004005): ScriptManager object is not set to a reference.]
    Telerik.Sitefinity.Modules.Pages.PageManager.ConfigureScriptManager(Page page, ScriptRef scripts, Boolean throwException) +367
    Telerik.Sitefinity.Web.UI.ContentUI.Views.Backend.ViewBase.OnPreRender(EventArgs e) +62
    System.Web.UI.Control.PreRenderRecursiveInternal() +126
    System.Web.UI.Control.PreRenderRecursiveInternal() +239
    System.Web.UI.Control.PreRenderRecursiveInternal() +239
    System.Web.UI.Control.PreRenderRecursiveInternal() +239
    System.Web.UI.Control.PreRenderRecursiveInternal() +239
    System.Web.UI.Control.PreRenderRecursiveInternal() +239
    System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3532

    ------------------------------------

    The only real difference between the pages is the content item in the main content area. Each 1 has a different type of content, such as news, blog, event, etc..

    Should content added in the template in a content area be rendered/available on the page? This actually works fine with the default templates or templates I make from the default templates.

  2. Radoslav Georgiev
    Radoslav Georgiev avatar
    3370 posts
    Registered:
    01 Feb 2016
    13 May 2010
    Link to this post
    Hi Todd Stanistreet,

    The first issue you are describing is a known bug, we have logged it for fixing. You have to Edit/Publish the page a coupe of times to see the content. As for the second issue, do you have a ScriptManager control on your physical master page? Could you try adding one to its markup and build the web application?

    Sincerely yours,
    Radoslav Georgiev
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  3. Todd Stanistreet
    Todd Stanistreet avatar
    4 posts
    Registered:
    19 Mar 2010
    16 May 2010
    Link to this post

    I added a script manager into the master page and this seems to have solved the problem for all the related pages.

    Thanks! :)

  4. Paolo
    Paolo avatar
    147 posts
    Registered:
    11 Jun 2009
    19 Nov 2010
    Link to this post
    Hello,
    since I'm new to SiteFinity can youp please tell me where should I put the ScriptManager? I've created a login usercontrol in the solution (opened from the sitefinity project manager)...but I only see a default page that doesn't look like a master page,
    thanks

    Paolo
  5. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    19 May 2017
    19 Nov 2010
    Link to this post
    Hi Paolo,

    You need to access the backend and create a page, then you should drop your control on a page after it has been registered through Toolbox section.

    Sincerely yours,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  6. Paolo
    Paolo avatar
    147 posts
    Registered:
    11 Jun 2009
    19 Nov 2010
    Link to this post
    Hello Ivan,
    I've tried but I'm not able to.... I've created a master page

    <%@ Master Language="C#" AutoEventWireup="true" CodeBehind="IFTest.master.cs" Inherits="SitefinityWebApp.IFTest" %>
     
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
     
    <head runat="server">
        <title></title>
        <asp:ContentPlaceHolder ID="head" runat="server">
        </asp:ContentPlaceHolder>
    </head>
    <body>
        <form id="form1" runat="server">
        <asp:scriptmanager ID="Scriptmanager1" runat="server"></asp:scriptmanager>
        <div>
            <asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server">
             
            </asp:ContentPlaceHolder>
        </div>
        </form>
    </body>
    </html>

    and I've added the custom user control as you've told me, I've followed step by step the procedure... no luck....
  7. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    19 May 2017
    19 Nov 2010
    Link to this post
    Hi Paolo,

    I cannot reproduce any of the issues you have.

    1. Why do not you use the dynamic template and themes which only require to do some clicks from the UI instead of creating a static master page with hardcoded place holders.

    2. Why do not you use the built in Login controls that we ship with Sitefinity RC.

    Kind regards,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  8. Paolo
    Paolo avatar
    147 posts
    Registered:
    11 Jun 2009
    19 Nov 2010
    Link to this post
    Hello Ivan,
    when I downloaded sitefinity I downloaded beta2 and not RC.... I'm downloading it right now and hope to use the features you're telling...
    Thanks
  9. Paolo
    Paolo avatar
    147 posts
    Registered:
    11 Jun 2009
    24 Nov 2010
    Link to this post
    Hello Ivan,
    what you mean with : "Why do not you use the dynamic template and themes which only require to do some clicks from the UI instead of creating a static master page with hardcoded place holders" ... my only need is to load a usercontrol written by me that uses a raduploader... this requires the scriptmanager but I don't know why using the standard templates it won't load it...
  10. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    19 May 2017
    24 Nov 2010
    Link to this post
    Hello Paolo,

    If you use the built-in templates we load the ASP.NET ScriptManager control. Even if you do not have a ScriptManager on your master page we load it automatically.

    Regards,
    Ivan Dimitrov
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
10 posts, 0 answered