0

Here is my HTML file:

{% load static %}
<!DOCTYPE html>
<html lang="en" dir="ltr">
  <head>
    <meta charset="utf-8">
    <title>{% block title %}{% endblock %}</title>

    <!-- Link to Bookstrap and stylesheet -->
    <link rel='stylesheet' href="{% static 'css/bootstrap.min.css' %}">
    <link rel='stylesheet' href="{% static 'css/style.css' %}">
    <script src="{% static 'js/bootstrap.min.js' %'}"></script>

  </head>
  <body class="bg-blue">

    <div class="container">
      <div class ="row">
        <div class ="col-lg-4 col-lg-offset-4">
          <br/>
          <br/>
          <br/>
          <div class="panel panel-body">
            <div class="panel-body">
              <h3 class="text-center text-uppercase"><b> {% block heading %}{% endblock %}</b></h3>
              <br/>
              {% block content %}{% endblock %}
          </div>
        </div>
      </div>
  </body>
</html>

I want to use the "bg-blue" class defined in my style.css.

.bg-blue{
  background-color: #3F3F63;
}

However it doesn't work. My boostrap and style.css are in the same folder. The Bootstrap loads, for example my text in centered and uppercase and the font is different.

I've also tried putting the class directly in the html file, and that works, but I want to be able to use style.css.

Edit: it works in Firefox but not Chrome, so it's not the code, any explain to this?

1
  • Try refreshing your cache in your browser Commented Aug 12, 2020 at 21:06

1 Answer 1

1

that is because you forgot to clear cache in chrome.press control + F5 to clear cache and load again.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.