Donate. I desperately need donations to survive due to my health

Get paid by answering surveys Click here

Click here to donate

Remote/Work from Home jobs

Flask loads only some parts of the css file

I have a css problem with Flask Running my app.py only "header" and "h2" of the style.css works. While testing the files alone away from Flask (index.html and its style.css) every thing is fine and the button and table styles are Ok , so what could be the reason behind this.

header{
  text-align: center;
  color: red;
  background-color: yellow;
}

h2{
  text-align: center;
  color: blue;
}

table {
    font-family: arial, sans-serif;
    border-collapse: collapse;
    width: 100%;
}

td, th {
    border: 1px solid #dddddd;
    text-align: left;
    padding: 8px;
}

.button{
  color: white;
  background-color: black;
}
<!DOCTYPE html>

<html>
  <head>
    <meta charset="utf-8">
    <title>Forums Workshop</title>
    <link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='style.css') }}">
  </head>
  <body>
    <header>
      <h1>One Million</h1>
    </header>
    <main>
      <h2><a href="#">Member profile</a></h2>
      <hr>
      <button class="button" type="button" name="button">Create</button>
      <table>
        <tr>
          <th>Title</th>
          <th>Edit</th>
          <th>Delete</th>
        </tr>
      </table>


    </main>

  </body>
</html>

Comments