Copied to clipboard

Flag this post as spam?

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


  • Stephen Biggs 6 posts 26 karma points
    Mar 29, 2011 @ 11:28
    Stephen Biggs
    0

    Error in ver 4.5.2: "please make sure that you do not have 2 templates with the same alias"

    I tried the select below to find the duplicated alias, but the count was only "1" for all 39 results. 

    SELECT     TOP (100) PERCENT COUNT(pk) AS TemplateNodeID, alias AS TemplateAliasName
    FROM         dbo.cmsTemplate AS ct
    GROUP BY alias

    Any suggestions how I can find/fix this ?

     

  • Daniel Bardi 927 posts 2562 karma points
    Mar 29, 2011 @ 11:41
    Daniel Bardi
    0

    If for some reason you have 2 templates with the same name (check Templates tree in Settings section)  you need rename one of them before you can proceed.

  • Stephen Biggs 6 posts 26 karma points
    Mar 29, 2011 @ 11:49
    Stephen Biggs
    0

    I can't see a duplicated template name on the tree.

    And

    SELECT     TOP (100) PERCENT dbo.umbracoNode.text, COUNT(dbo.cmsTemplate.pk) AS Expr1
    FROM         dbo.cmsTemplate INNER JOIN
                          dbo.umbracoNode ON dbo.cmsTemplate.nodeId = dbo.umbracoNode.id
    GROUP BY dbo.umbracoNode.text
    ORDER BY Expr1 DESC

    shows count of "1" for all 39 entries.

  • Daniel Bardi 927 posts 2562 karma points
    Mar 29, 2011 @ 11:58
    Daniel Bardi
    0

    Verify the masterpage references in the the templates.. make sure they are all valid.

    I would also check the physical masterpage files in the masterpages folder.. make sure they are valid.

    You call also backup the masterpages (important) folder, then wipe the templates (using the ui) and re-add them.. might clear up the glitch.

  • Stephen Biggs 6 posts 26 karma points
    Mar 29, 2011 @ 12:28
    Stephen Biggs
    0

    SELECT     dbo.cmsTemplate.master, cmsTemplate_1.alias, cmsTemplate_1.nodeId
    FROM         dbo.cmsTemplate INNER JOIN
                          dbo.cmsTemplate AS cmsTemplate_1 ON dbo.cmsTemplate.pk = cmsTemplate_1.pk
    GROUP BY dbo.cmsTemplate.master, cmsTemplate_1.alias, cmsTemplate_1.nodeId

    Shows that 37 of the 39 templates have a defined master page which does exist.The other two are top of the template tree with a master page of "None". and are listed with nulls in the "master" foreign key. I'd guess that means the masterpage references are all valid...?

    There are 40 files in the masterpages folder. One for a "test1" template (which I deleted) How can I determin if any of the other 39 are all invalid...?

     

     

  • Stephen Biggs 6 posts 26 karma points
    Mar 29, 2011 @ 13:16
    Stephen Biggs
    0

    I deleted the most rescently modified template and recreated that.

    That fixed the error in saving templates. But resulted in the document type for that page having no assigned template.

    So I recreated the entry in table cmsDocumentType, fortunately that only has 3 fields so I could guess all their values.

    Anything else I might need to repair as a result of this...???

     

     

     

  • Daniel Bardi 927 posts 2562 karma points
    Mar 29, 2011 @ 20:01
    Daniel Bardi
    0

    Reassign the template via the document type UI, not the database

  • Stephen Biggs 6 posts 26 karma points
    Apr 05, 2011 @ 12:01
    Stephen Biggs
    0

    Carefully checking of the last Template saved before error occured, I found a syntax error in HTML.

    Specifically, incorrectly nested <li></li> tags.

    This error saved without an error message. But would not allow further edits to the templates. Resulting in the missleading error message. Since at no time were there "2 templates with the same alias".

Please Sign in or register to post replies

Write your reply to:

Draft