Deploying update to master page resets content block?

Posted by Community Admin on 03-Aug-2018 17:50

Deploying update to master page resets content block?

All Replies

Posted by Community Admin on 06-Jun-2011 00:00

I created a master page that went into sitefinity. After that, I added a content block widget to a page that was based on the master page. Then I changed the css class name from the default of sfContentBlock to one of ours.

When I deployed an updated master page, it seems like it set the css class name back to sfContentBlock. Will that happen every time?

Posted by Community Admin on 07-Jun-2011 00:00

Hi Eric,

We tried to reproduce the issue with no luck. Here are the steps:

1. We created a simple master page with the following code:

<%@ Master Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head id="Head1" runat="server">
    <title></title>
    <meta http-equiv="content-type" content="text/html; charset=utf-8" />    
</head>
<body class="main-body">
    <form id="form1" runat="server">
        <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>
        <div id="wrapper">
                <asp:contentplaceholder id="all" runat="server" />
        </div>
         
   </form>
</body>
</html>

2. We placed the file in ~/App_Data/Sitefinity/WebsiteTemplates/test/App_Master/test
3. We created a new template test based on master page (test.master)
4. We created a new page base on the test template
5. We added a new content block in the placeholder and  changed the CSS Class property from sfContentBlock to someOtherCSSClass. Then then saved the page
6. We made some changes on the master page: change all the id's - these of the placeholders and these of div elements that holds them and added a new placeholder so the code looks like:

<%@ Master Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head id="Head1" runat="server">
    <title></title>
    <meta http-equiv="content-type" content="text/html; charset=utf-8" />    
</head>
<body class="main-body">
    <form id="form1" runat="server">
        <asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>
        <div id="wrapper1">
                <asp:contentplaceholder id="all2" runat="server" />
        </div>
        <div id="wrapper2">
                <asp:contentplaceholder id="all3" runat="server" />
        </div>
         
   </form>
</body>
</html>

After the changes we opened the page and the new placeholder was added but the changed CSS class of the content block that was in the first placeholder is still someOtherCSSClass.

Can you provide us more information about the changes that you have made on the master page so we can reproduce the problem?


Greetings,
Jordan
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

This thread is closed