Click here to Skip to main content
16,022,538 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi
I have a master page with header and menu(vertical order).after applying this master page in aspx page it will not show the menu details.

what is the problem?Can any one help me to solve this?

here is my code
ASP.NET
<body class="body"  style="margin-top: 0; margin-left: 50px; margin-right: 50px; 
background-attachment: fixed">
    <form id="form1"  runat="server"  autocomplete="off">
        <asp:ScriptManager ID="ScriptManager1" runat="server" AsyncPostBackTimeout="15000">
           
           <table align="center" style="width: 848px; vertical-align:top; height: 520px">
                <tr>
                    <td style="width: 1100px; height: 378px">
        <asp:Panel ID="mainpanel" runat="server" BackColor="white"  Width="100%" Style="height: 545px;">
           
            <asp:ContentPlaceHolder ID="HeaderArea" runat="server">
                <asp:Panel ID="immsHeading" runat="server" Width="100%" BackColor="White" Height="70px">
                    <table style="width: 81%; height: 32px">
                     <tr>
                            <td style="height: 57px; width:169px; background-image:removed(images/topbg.jpg);">
                                <div style="float: left; height: 71px; margin-removed 10px; width: 1164px;">
                                <asp:Image ID="img1" runat="server" ImageUrl="~/images/logo1.png" Height="39px" Width="240px" ForeColor="White" />
                                    <!--<span id="lblHeader" style="font-size:Larger;font-weight:bold; color: white;">Strike</span>
                                            <span id="Label1" style="font-size:Larger;font-weight:bold; color: white;"> A Price </span>
                                            <span id="Label2" style="font-size:Larger;font-weight:bold; color: white;">.com </span>-->
                                   <asp:LinkButton ID="lblMyaccounts" runat="server" Font-Bold="True"
                                        Font-Italic="False" Font-Names="Arial" Font-Size="12px" Font-Underline="True"
                                        ForeColor="blue" Height="13px"  Text="My Accounts" Width="83px"> 
                                        <asp:LinkButton ID="lnkLogout" runat="server" OnClientClick="statwords('Go To Login Page')"
                                            Font-Size="Small" ForeColor="blue" Text="LogOut" Width="50px" Font-Names="TimesNewRoman" Font-Bold="True" OnClick="lnkLogout_Click"></div></td>
                                   <!-- <td align="right" style="height: 57px; background-image:removed(images/topbg.jpg);">
                                        <asp:Label ID="days_count" runat="server" Visible="False">
                                        <asp:Label ID="Label3" runat="server" Visible="False" Width="55px">
                                    </td>-->                                    
                        </tr>                    
                    </table>
            <table style=" text-align:center; width:100%; background-color: white; border:goldenrod 1px solid; height: 100px;">
            <tr>
                    <td style="width: 107%; height: 180px;">
                        <asp:ContentPlaceHolder ID="MainArea" runat="server">
                         <table style=" text-align:center; width:100%; background-color: white; height: 274px;">
       
       <tr>
           <td align="left" style="height: 60px; width: 62px;" valign="top">
        
                <asp:Menu ID="Menu1" runat="server" Font-Bold="True" Font-Names="Arial" Font-Size="12px"
                    ForeColor="White" Height="380px" Orientation="Vertical" Width="110px" BackColor="#EDA505" OnMenuItemClick="Menu1_MenuItemClick">
                    <staticmenustyle backcolor="#EDA505" />
                    <statichoverstyle forecolor="#FFFF80" />
                    <items>
                        <asp:MenuItem  Text="Registration" Value="NewRegistration">
                        
                        <asp:MenuItem  Text="View Details" Value="Registration">
                        <asp:MenuItem  Text="Change Password" Value="ChangePassword">
                        
                         <asp:MenuItem  Text="Update Client" Value="New Item">
                        
                        <asp:MenuItem  Text="Crawling" Value="New Item">
                       
                        <asp:MenuItem Text="Push to DB" Value="Transform  ExcelTable  To SqlserverTable ">
                    </items>
                </td>
        </tr>
        </table>
                    </td>
                  </tr>
             </table>
                        <br />
      </td>
                </tr>
               <tr>
                 <td align="center" valign="top" class="green" style="height: 57px; width: 80%;">
      <div style="height: 71px; margin-removed1px; width:100%; background-image:removed(images/topbg.jpg);">
                           <span class="style14" style="color:White;">Copyright © 2011
                                 <a style="color: White" title="StrikeAPrice" href="http://www.strikeaprice.com" target="_parent">StrikeAPrice</a></span></div></td>
                  </tr>
           </table>
    </form>
</body>
Posted
Updated 5-Jan-12 18:22pm
v3
Comments
Ankur\m/ 6-Jan-12 0:37am    
To start debugging the issue, inspect the page/elements with firebug.

you are not close all tages and style s make sure that all code of your master page and nothing will be in asp:ContentPlaceHolder tag.
 
Share this answer
 
v2
Comments
RaisKazi 6-Jan-12 1:57am    
Edited: Using "code" tag.
check this is my master
ASP.NET
<div class="wrap clearfix">
       <div style="text-align: left; background-color: #396184; width: 970px;">
           <table cellpadding="0" cellspacing="0">
               <tr>
                   <td>
                       <asp:Menu ID="mainMenu" runat="server" Orientation="Horizontal" BorderStyle="None"
                           ItemWrap="True" Width="400px" CssClass="padL15">
                           <StaticMenuStyle HorizontalPadding="1px" />
                           <StaticMenuItemStyle ForeColor="White" HorizontalPadding="1px" />
                           <DynamicMenuStyle BackColor="#e1e1e1" />
                           <DynamicMenuItemStyle ForeColor="#3f6080" />
                           <DynamicMenuStyle Width="150px" Height="70px" HorizontalPadding="15px" />
                           <Items>
                               <asp:MenuItem Text="ADMIN" Value="Admin">
                                   <asp:MenuItem Text="New User" Value="USER" NavigateUrl="~/RegistrationForm.Aspx"
                                       SeparatorImageUrl="~/images/seprator.jpg"></asp:MenuItem>

                           </Items>
                       </asp:Menu>
                   </td>

               </tr>
           </table>
       </div>
   </div>
   <div>
       <asp:contentplaceholder id="ContentPlaceHolder1" runat="server">


       </asp:contentplaceholder>
   </div>

and one aspx.page which under the that master
ASP.NET
<asp:contentplaceholder id="ContentPlaceHolder1" runat="server">
          <table>
                       //your code..........
                  </table>
        </asp:contentplaceholder>
 
Share this answer
 
v2
Comments
RaisKazi 6-Jan-12 1:56am    
Edited: Added "pre" tag.
[no name] 6-Jan-12 2:15am    
thank u RaisKazi
i forget it..........

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900