Error while using Master Template

Posted by Community Admin on 03-Aug-2018 15:30

Error while using Master Template

All Replies

Posted by Community Admin on 12-Jan-2011 00:00

Hi,

I am getting this error while using the master template that I have created. Could you please let me what am I missing. I have attached the error message image.Thanks.

My Master page is a follows:

<%@ Master Language="C#" AutoEventWireup="true" CodeBehind="Default.master.cs" Inherits="SitefinityWebApp.App_Master.GITR.Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "www.w3.org/.../xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head runat="server">
    <title>GITR - Home</title>
<meta http-equiv="content-type" content="application/xhtml+xml; charset=UTF-8" />

<link rel="shortcut icon" href="images/favicon32.ico">
<link rel="apple-touch-icon" href="images/apple-touch-icon.png">
<link rel="stylesheet" href="styles/basicReset.css" type="text/css">
<link rel="stylesheet" href="styles/screen.css" type="text/css">
<link rel="stylesheet" href="styles/handheld.css" media="handheld" >
<link rel="stylesheet" href="styles/start/jquery-ui-1.8.custom.css" type="text/css" />

<script src="includes/modernizr-1.js"></script>
<script src="includes/jquery-1.4.2.min.js"></script>
<script src="includes/jquery-ui-1.8.custom.js"></script>
<script src="includes/plugins.js"></script>
<script src="includes/script.js"></script>

<script>

</script>

<!--[if lt IE 7 ]> <body class="ie6"> <![endif]-->
<!--[if IE 7 ]>    <body class="ie7"> <![endif]-->
<!--[if IE 8 ]>    <body class="ie8"> <![endif]-->
<!--[if IE 9 ]>    <body class="ie9"> <![endif]-->
<!--[if (gt IE 9)|!(IE)]><!-->
<!-- InstanceBeginEditable name="head" -->
<link rel="stylesheet" type="text/css" href="styles/billboard.css">
<link rel="stylesheet" type="text/css" href="styles/spotlight.css">
<link href="styles/jqueryTools.scrollable.horizontal.css" type="text/css" rel="stylesheet" >
<link href="styles/jqueryTools.scrollable.buttons.css" type="text/css" rel="stylesheet" >
<link href="styles/jqueryTools.scrollable.navigator.css" type="text/css" rel="stylesheet" >

<script src="includes/billboard2.js"></script>
<script src="includes/quickpoll.js"></script>
<script src="includes/jqueryTools.all.min.js" type="text/javascript"></script>
<script src="includes/jqueryTools.spotlights.js" type="text/javascript"></script>      

</head>
<body>
<form runat="server">
    <div id="container">
        <header>
            <div id="bannerBar">
                <asp:ContentPlaceHolder ID="NavPlaceHolder" runat="server" />
            </div>
            <div id="topNavBar">
                <asp:ContentPlaceHolder ID="NavPlaceHolder" runat="server" />
            </div>
        </header>
        <div id="main">
            <div id="mainLeft">
            <!-- InstanceBeginEditable name="mainLeft" -->
                <div style="display: ;" class="billboardWrapper">
                    <div class="billboard">
                        <!--Content block for Billboard Start-->
                            <div class="items">                    
                                <asp:ContentPlaceHolder ID="NavPlaceHolder" runat="server" />
                                <div class="block"></div>
                            </div>
                    </div>
                        <!--Content block for Billboard End-->
                </div>
            </div>           
            <div class="scrollableWrapper" style="display:none;">
                <a class="prev browse left"></a>
                <a class="next browse right"></a>
                    <div class="navi"></div>
                    <div class="scrollable">
                        <!-- root element for the items -->
                            <div class="items">
                                <div class="colGroup">
                                    <asp:ContentPlaceHolder ID="NavPlaceHolder" runat="server" />
                                </div>
                                <div class="colGroup">
                                    <asp:ContentPlaceHolder ID="NavPlaceHolder" runat="server" />
                                </div>
                            </div>
                    </div>
            </div>
            <div id="quickLinks" class="clearfix" style="clear: both; margin-top: 20px; width: 680px;">
                <!--Content block for QuicklinkLeft Start-->
                    <div id="quickLinksLeft" class="quickLinksCol">
                        <asp:ContentPlaceHolder ID="NavPlaceHolder" runat="server" />
                    </div>
                <!--Content block for QuicklinkLeft End-->
                <!--Content block for QuicklinkRight Start-->
                    <div id="quickLinksRight" class="quickLinksCol">
                        <asp:ContentPlaceHolder ID="NavPlaceHolder" runat="server" />
                    </div>
                <!--Content block for QuicklinkRight End-->
            </div>
            <!-- InstanceEndEditable --></div>
            <!--  #mainLeft//-->
            <div id="mainRight">
            <!-- InstanceBeginEditable name="mainRight" --><!-- #BeginLibraryItem "/Library/sidebars.lbi" -->
                <div class="sidebar">
                    <div class="sidebarTitle">Questions ?</div>
                        <div class="sidebarBody">
                            <!--Content block for Questions Start-->
                            <asp:ContentPlaceHolder ID="NavPlaceHolder" runat="server" />
                        </div>
                </div>
                <div class="sidebar">
                    <div class="sidebarTitle">Self Help</div>
                        <div class="sidebarBody">
                            <!--Content block for SelfHelp Start-->
                            <asp:ContentPlaceHolder ID="NavPlaceHolder" runat="server" />
                            <!--Content block for SelfHelp End-->
                        </div>
                </div>
            <!-- #EndLibraryItem -->
                <div class="sidebar">
                    <div class="sidebarTitle">Quick Poll</div>
                        <div class="sidebarBody">
                            <div class="panel" id="">
                                <div class="panelBodyQP">
                                    <div class="pollpanel" id="pollPanel">
                                        <div id="poll_messagePanel"></div>
                                        <div id="poll_resultPanel" valign="top"></div>
                                        <div id="poll_interactionPanel" valign="top">
                                            <h1></h1>
                                            <div></div>
                                            <input name="poll:reqResponses" id="poll_reqResponses" value="0" type="hidden">
                                            <input name="poll:reqId" id="poll_reqId" value="9cd01327-b5c5-4713-9080-5cbd73b0e515" type="hidden">
                                            <p><strong>Rate your new Total Rewards site:</strong></p>
                                            <table id="poll_ssPr_1" border="0">
                                            <tbody>
                                            <tr>
                                            <td><input id="poll_ssPr_1_0" name="poll:ssPr_1" value="a" type="radio">
                                            <label for="poll_ssPr_1_0">Outstanding</label></td>
                                            </tr>
                                            <tr>
                                            <td><input id="poll_ssPr_1_1" name="poll:ssPr_1" value="b" type="radio">
                                            <label for="poll_ssPr_1_1">Above average</label></td>
                                            </tr>
                                            <tr>
                                            <td><input id="poll_ssPr_1_2" name="poll:ssPr_1" value="c" type="radio">
                                            <label for="poll_ssPr_1_2">Average</label></td>
                                            </tr>
                                            <tr>
                                            <td><input id="poll_ssPr_1_3" name="poll:ssPr_1" value="d" type="radio">
                                            <label for="poll_ssPr_1_3">Less than average</label></td>
                                            </tr>
                                            <tr>
                                            <td><input id="poll_ssPr_1_4" name="poll:ssPr_1" value="e" type="radio">
                                            <label for="poll_ssPr_1_4">Poor</label></td>
                                            </tr>
                                            </tbody>
                                            </table>
                                        </div>
                                        <div valign="top" align="center"> <br>
                                            <input name="poll:submitButton" value="Vote" id="poll_submitButton" type="submit">
                                        </div>
                                    </div>
                                </div>
                            </div>
                        <br>
                        </div>
                    </div>
        <!-- InstanceEndEditable -->
                </div> 
        <!-- #mainRight//-->
        </div>
        <!-- #main//-->
        <footer>
            <asp:ContentPlaceHolder ID="NavPlaceHolder" runat="server" />
        </footer>
    </div>       
        <!--! end of #container -->
        <div id="bodyWrapper">hello</div>
            <p>&nbsp;</p><p>&nbsp;</p><p>&nbsp;</p><p>&nbsp;</p><p>&nbsp;</p>
</form>
</body>
</html>

Posted by Community Admin on 14-Jan-2011 00:00

Hello Vinod,

 I could not reproduce the reported error. I have found several issues related to your master page:

  1. All content place holders are declared with the same ID - NavPlaceHolder (ContentPlaceHolders require unique IDs)
  2. There are unclosed <link>  tags
  3. There are unclosed <input> tags

If the above does not help, please describe the exact steps for reproducing the problem.

Regards,
Pepi
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

Posted by Community Admin on 18-Jan-2011 00:00

I'm also getting this error when trying to create template from a master page.

Value cannot be null.
Parameter name: g

<%@

Master Language="C#" AutoEventWireup="true" CodeBehind="Master.master.cs" Inherits="SitefinityMasterpages2.Master" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "www.w3.org/.../xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title></title>
</
head>
<
body>
<form id="form1" runat="server">
<div class="header container_12">
<asp:ContentPlaceHolder ID="ContentPlaceHolder1" runat="server" />
</div>
<div class="clear"></div>
<div class="body container_12">
<asp:ContentPlaceHolder ID="ContentPlaceHolder2" runat="server" />
</div>
<div class="clear"></div>
<div class="footer container_12">
<asp:ContentPlaceHolder ID="ContentPlaceHolder3" runat="server" />
</div>
<div class="clear"></div>
</form>
</
body>
</
html>

 

 

 

 

 

Posted by Community Admin on 19-Jan-2011 00:00

Turns out the error was because the file it was trying to inherit from didn't exist.  Removing the Inherits tag in the master page or uploading the appropriate file fixes this problem.

Posted by Community Admin on 19-Jan-2011 00:00

Hello,

Our QAs succeeded to reproduce the issue. Actually, the problem appears when you try to set master page for already existing template (Actions menu > Base Template > Use you own .master file). So, currently the workaround is to set the required master page when creating the template:
1. Click Create a template button
2. Fill the Name and choose Use template option
3. Click Select another Template button
4. Click Use you own .master file
5. Select the master page
6. Create the template and go to add content or return to the grid

The bug is logged and will be scheduled for fix for the next release.

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

This thread is closed