Copied to clipboard

Flag this post as spam?

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


  • Ben Merrick 12 posts 32 karma points
    Oct 28, 2009 @ 20:38
    Ben Merrick
    0

    Child pages not using CSS and Master template

    I have a website that the clients have created that contains pages that drill-down into three levels.  When navigated to, each third level page will not show any of the CSS styles in the StyleSheet nor will it apply anything from the Master template (even though the template used to create the document type is a direct descendant of the master template).  The document types for both the parent pages and the children pages are the same (although I don't know if that makes a difference).

    Please help me understand why the lowest level pages will not show any CSS styles or display the content from the master page template.

  • Rich Green 2246 posts 4008 karma points
    Oct 28, 2009 @ 21:14
    Rich Green
    0

    Can you post the html source code of lowest level page?

     

  • Ben Merrick 12 posts 32 karma points
    Oct 28, 2009 @ 22:01
    Ben Merrick
    0

            <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
        <html>
        <head>
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
            <title>Enterprise</title>
            <link href="css/Style.css" rel="stylesheet" type="text/css" />
        <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.2.6/jquery.min.js"></script>
        <script src="lib/jquery.cookie.js" type="text/javascript"></script>
        <script src="jquery.treeview.js" type="text/javascript"></script>
        <script type="text/javascript" src="demo/demo.js"></script>
             <script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
             <style type="text/css">
            body
            {
                background-image: url(images/background.jpg);
            }        
        </style>
        </head>
        <body>
            <table width="762" border="0" align="center" cellpadding="1" cellspacing="0" bgcolor="#dcd9d9">
                <tr>
                    <td>
                        <table border="0" cellpadding="0" cellspacing="8" bgcolor="#FFFFFF" width="100%">
                            <tr>
                                <td class="TopLinks">
                                    <div align="right">
                                        <a href="/home.aspx" class="util">Home</a>&nbsp; |&nbsp;
                                        <a href="/careers.aspx" class="util">Career Opportunities</a>&nbsp; |&nbsp;
                                        <a href="/contact.aspx" class="util">Contact Us</a>
                                    </div>
                                </td>
                            </tr>
                            <tr>
                                <td bgcolor="#FFFFFF">
                                    <table border="0" cellspacing="0" cellpadding="1">
                                        <tr>
                                            <td width="192" style="padding-right: 0px">
                                                <a href="/home.aspx">
                                                    <img src="images/logo.gif" alt="Enterprise" width="105" height="60" hspace="45" vspace="40" border="0" />
                                                </a>
                                                
        <div><img src="images/spacer.gif" alt="" style="width: 192px; height: 2px; background-color: #cdcfd2;" /><p class="mainNavselected"><img src="images/arrow_red.gif" /><a href="/about-us.aspx" atl="" class="main"> About Us</a></p><img src="images/spacer.gif" alt="" style="width: 192px; height: 1px; background-color: #cdcfd2;" /><p class="secnav"><a href="/about-us/team.aspx" atl="" class="secnavlink" style="color:#bf1b11">  Team</a></p><img src="images/spacer.gif" alt="" style="width: 192px; height: 1px; background-color: #cdcfd2;" /><img src="images/spacer.gif" alt="" style="width: 192px; height: 1px; background-color: #cdcfd2;" /></div>
     
                        <br />                                            
                                            </td>
                                            <td valign="top">                                            
                        
        
                                            
                    </td>
                                        </tr>
                                    </table>
                                    <p>
                                    </p>
                                </td>
                            </tr>
                            <tr>
                                <td bgcolor="#FFFFFF" class="footer">
                                    © 2006-2009 All Rights Reserved. &nbsp;|&nbsp;
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
            </table>
     
        </body>
        </html>

  • dandrayne 1138 posts 2262 karma points
    Oct 28, 2009 @ 22:25
    dandrayne
    0

    Hi there

    Firstly, your css seems to be using a relative link ,so when you move down to a "subfolder" it won't work.  Try changing it to 

    <link href="/css/Style.css" rel="stylesheet" type="text/css" />

    The same goes for your script files.

    As for the master template, do you also have a content area placeholder in the master template, and a content area in the child?  If not, you should install runway and pick it apart, to see how the templates fit together.  umbraco.tv is also full of useful info.

    Dan

     

  • Ben Merrick 12 posts 32 karma points
    Oct 28, 2009 @ 22:33
    Ben Merrick
    0

    @dandrayne

    Stupid mistakes...I forgot to put a leading "/" when referencing a link in my Master template as well as a few macros that load up menus and other items.  After combing through those files and adding the leading "/", everything works as it should.

Please Sign in or register to post replies

Write your reply to:

Draft