0

以下が機能しない理由を理解しようとしています。上部にナビゲーション バーを表示しようとしていますが、コンパス ファイルと scss ファイルを使用していますが、これは基本的な CSS であり、理解できません。sass-lang.com からコピーして貼り付け、名前だけを変更しました

以下は私のscssファイルです

#top-navigation {
  width: 80%;
  height: 23px;

  ul { list-style-type: none; }
  li {
    float: left;
    a { font-weight: bold; }
  }
}

以下は私のbase.htmlです

{% extends "skeleton.html" %}
{% load zinnia_tags i18n %}
{% load url from future %}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
    <link rel="stylesheet" href="/style.css" />
    <title>{% block title %}User test{% endblock %}</title>
</head>

<body>       
        {% block header %}
    <div class ="container">
    <div id="header">
<ul class="top-navigation">
              <li>  
                    <a href="{% url "home" %}">{% trans "Home" %}</a>  
             </li>
                {% if user.is_authenticated %}
                <li> {% trans "Logged in" %}: {{ user.username }} </li>
                {% endif %}

          <li>
            <a href="/blog/feeds/" title="RSS Feed of latest entries" class="feeds">
              RSS Feed
            </a>
          </li>
        </ul>
    </div>
    </div>


    <hr />

        {% endblock %}



        {% block sidebar %}
        <div id="sidebar">
            <ul>
                <li>One</li>
                <li>Two</li>
                <li>Three</li>
            </ul>
        </div>
        {% endblock %}



    <div id="content">
        {% block content %}{% endblock %}
    </div>

    <div id="footer">
        {% block footer %}
        <hr />
        <p>this is the footer</p>
        {% endblock %}
    </div>
</body>

</html>

index.html

{% extends "base.html" %}
{% load i18n zinnia_tags %}
{% load url from future %}
{% block title %}IVLoop.com{% endblock %}

</div>
    {% block content %}

        <h1>IVLoop.com</h1>
        <h2>Isla Vista Survival Handbook</h2>
        <h3>Phone Numbers and Links to all the stuff u need. Like food, fixing broken windows, 
        door locks and pluming. IVLoop.com is your IV survival guide</h3>

<p>IV loop is the term to describe the biz and res area around the loop in iv 
“did the Loop” generally means that you had a pitcher at the fine establishments located around the Isla Vista Loop.
 Start at Javan’s on Embarcadero Del Norte
then across to IVBC now remodeled as Embarcadero Hall, once the building was on fire… find out more and submit us your findings to be posted thanks
then down and around the loop for a beer at Super Cuca’s however they are moving next to Woodstock’s
up on Del Mar to Déjà Vu 
next is Giovanni’s 
across they way to El Sitio’s
Sam’s To Go 
Study Hall 
then over to Dublin’s
then Chino’s 
On the Side and Woodstock’s to finish of next to Javan’s
Please drink Responsibly! 

Is it isla as in island or is it isla as in is and why? </p>

{% endblock %}

</div>

私が得る結果は

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xml:lang="en-us" lang="en-us" version="-//W3C//DTD XHTML 1.1//EN" xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <title>IVLoop.com</title>
    <meta http-equiv="content-type" content="text/html; charset=utf-8" />
    <meta http-equiv="cache-control" content="public" />
    <meta name="robots" content="follow, all" />
    <meta name="language" content="en-us" />
    <meta name="viewport" content="width=device-width; initial-scale=1.0;" />
    <meta name="description" content="Browse through a few featured Isla Vista Restaurants and we are here to take your order. 
Call night or day (805)689-6969 or order online" />
    <meta name="keywords" content="delivery,food,take-out " />
    <meta name="author" content="Brian Scott Carpenter" />

    <link rel="pingback" href="/xmlrpc/" />
    <link rel="shortcut icon" href="/static/img/favicon.ico" />
    <link rel="home" href="/" />
    <link rel="stylesheet" type="text/css" media="screen, projection" href="/static/css/screen.css" />
    <link rel="stylesheet" type="text/css" media="print" href="/static/css/print.css" />
    <!--[if lt IE 8]>
        <link rel="stylesheet" type="text/css" media="screen, projection" href="/static/zinnia/css/ie.css" />
    <![endif]-->


  </head>
  <body class="skeleton ">
    <div class="container">

    <div class ="container">
<ul class="top-navigation">
              <li>  
                    <a href="/">Home</a>  
             </li>


          <li>
            <a href="/blog/feeds/" title="RSS Feed of latest entries" class="feeds">
              RSS Feed
            </a>
          </li>
        </ul>



    <hr />



        <div id="sidebar">
            <ul>
                <li>One</li>
                <li>Two</li>
                <li>Three</li>
            </ul>
        </div>



        <h1>IVLoop.com</h1>
        <h2>Isla Vista Survival Handbook</h2>
        <h3>Phone Numbers and Links to all the stuff u need. Like food, fixing broken windows, 
        door locks and pluming. IVLoop.com is your IV survival guide</h3>

<p>IV loop is the term to describe the biz and res area around the loop in iv 
“did the Loop” generally means that you had a pitcher at the fine establishments located around the Isla Vista Loop.
 Start at Javan’s on Embarcadero Del Norte
then across to IVBC now remodeled as Embarcadero Hall, once the building was on fire… find out more and submit us your findings to be posted thanks
then down and around the loop for a beer at Super Cuca’s however they are moving next to Woodstock’s
up on Del Mar to Déjà Vu 
next is Giovanni’s 
across they way to El Sitio’s
Sam’s To Go 
Study Hall 
then over to Dublin’s
then Chino’s 
On the Side and Woodstock’s to finish of next to Javan’s
Please drink Responsibly! 

Is it isla as in island or is it isla as in is and why? </p>



        <hr />
        <p>this is the footer</p>

  </body>
</html>

コンパスが機能していることはわかっています。なぜなら、他のクラスで作業するときにコンパスが機能するからです。ありがとう

4

1 に答える 1

0

問題はbase.htmlにありました

<div id ="top-navigation">

then <ul>

彼らはどこで結合した

于 2013-03-20T22:35:26.380 に答える