Edited the templates so that they use styles.css

parent 870f109a
{% extends 'base.html' %} {% extends 'base.html' %}
{% block title %} {{ author.first_name }} {{ author.last_name }} {% endblock %} {% block title %} {{ author.first_name }} {{ author.last_name }} {% endblock %}
{% block header %} {{ author.first_name }} {{ author.last_name }} {% endblock %} {% block header %} {{ author.first_name }} {{ author.last_name }} {% endblock %}
{% block content %} {% block content %}
<p> <p>
{{ author.age }} <br> {{ author.age }} <br>
...@@ -12,11 +14,13 @@ ...@@ -12,11 +14,13 @@
<ul> <ul>
{% for work in author.works.all %} {% for work in author.works.all %}
<li> <li>
<a href="{{ work.get_absolute_url }}">{{ work.title }}</a> <br> <a href="{{ work.get_absolute_url }}" class = "item">{{ work.title }}</a> <br>
</li> </li>
{% endfor %} {% endfor %}
</ul> </ul>
{% endblock %}
{% block navbar %}
<a href="http://localhost:8000/home/">Home</a> <a href="http://localhost:8000/home/">Home</a>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="http://localhost:8000/books/">Books</a> <a href="http://localhost:8000/books/">Books</a>
......
{% extends 'base.html' %} {% extends 'base.html' %}
{% block title %} My Favorite Authors {% endblock %} {% block title %} My Favorite Authors {% endblock %}
{% block header %} Lance's Favorite Authors: {% endblock %} {% block header %} Lance's Favorite Authors: {% endblock %}
{% block content %} {% block content %}
<ul> <div id = "object_bar">
{% for author in author_list %} <ul id = "object_list">
<li> {% for author in author_list %}
<a href="{{ author.get_absolute_url }}">{{ author.first_name }} {{ author.last_name }}</a> <br> <li>
</li> <a href="{{ author.get_absolute_url }}" class = "item">{{ author.first_name }} {{ author.last_name }}</a> <br>
{% endfor %} </li>
</ul> {% endfor %}
</ul>
</div>
{% endblock %}
{% block navbar %}
<a href="http://localhost:8000/home/">Home</a> <a href="http://localhost:8000/home/">Home</a>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="http://localhost:8000/books/">Books</a> <a href="http://localhost:8000/books/">Books</a>
......
{% extends 'base.html' %} {% extends 'base.html' %}
{% block title %} {{ books.title }} {% endblock %} {% block title %} {{ books.title }} {% endblock %}
{% block header %} {{ books.title }} {% endblock %} {% block header %} {{ books.title }} {% endblock %}
{% block content %} {% block content %}
<p> <p>
<a href="{{ books.author.get_absolute_url }}"> <li>
<a href="{{ books.author.get_absolute_url }}" class = "item">
{{ books.author.first_name }} {{ books.author.last_name }} {{ books.author.first_name }} {{ books.author.last_name }}
</a> <br> </a> <br>
</li>
{{ books.publisher }} <br> {{ books.publisher }} <br>
{{ books.year_published }} <br> {{ books.year_published }} <br>
{{ books.ISBN }} <br> {{ books.ISBN }} <br>
{{ books.blurb }} <br> {{ books.blurb }} <br>
</p> </p>
{% endblock %}
{% block navbar %}
<a href="http://localhost:8000/home/">Home</a> <a href="http://localhost:8000/home/">Home</a>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="http://localhost:8000/books/">Books</a> <a href="http://localhost:8000/books/">Books</a>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="http://localhost:8000/authors/">Authors</a> <a href="http://localhost:8000/authors/">Authors</a>
{% endblock %} {% endblock %}
\ No newline at end of file
{% extends 'base.html' %} {% extends 'base.html' %}
{% block title %} My Favorite Books {% endblock %} {% block title %} My Favorite Books {% endblock %}
{% block header %} Lance's Favorite Books: {% endblock %} {% block header %} Lance's Favorite Books: {% endblock %}
{% block content %} {% block content %}
<ul> <div id = "object_container">
{% for book in book_list %} <ul id = "object_list">
<li> {% for book in book_list %}
<a href="{{ book.get_absolute_url }}">{{ book.title }}</a> <br> <li>
</li> <a href="{{ book.get_absolute_url }}" class = "item">{{ book.title }}</a> <br>
{% endfor %} </li>
</ul> {% endfor %}
</ul>
</div>
{% endblock %}
{% block navbar %}
<a href="http://localhost:8000/home/">Home</a> <a href="http://localhost:8000/home/">Home</a>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="http://localhost:8000/authors/">Authors</a> <a href="http://localhost:8000/authors/">Authors</a>
{% endblock %} {% endblock %}
\ No newline at end of file
{% extends 'base.html' %} {% extends 'base.html' %}
{% block title %} My Favorite Books & Authors {% endblock %} {% block title %} My Favorite Books & Authors {% endblock %}
{% block header %} Welcome to Lance's Database of Favorite Books and Authors! {% endblock %} {% block header %} Welcome to Lance's Database of Favorite Books and Authors! {% endblock %}
{% block content %} {% block content %}
<p> <p>
Hello, I'm Lance! This is a short collection of my favorite books and authors. While I'm open to most types Hello, I'm Lance! This is a short collection of my favorite books and authors. While I'm open to most types
of books, I particularly enjoy fantasy books, especially those with magic! of books, I particularly enjoy fantasy books, especially those with magic!
</p> </p>
{% endblock %}
{% block navbar %}
<a href="http://localhost:8000/books/">Books</a> <a href="http://localhost:8000/books/">Books</a>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="http://localhost:8000/authors/">Authors</a> <a href="http://localhost:8000/authors/">Authors</a>
{% endblock %} {% endblock %}
\ No newline at end of file
<!DOCTYPE html> <!DOCTYPE html>
{% load static %}
<html lang="en"> <html lang="en">
<link rel="stylesheet" href="{% static 'styles.css' %}">
<head> <head>
<title> {% block title %} Title {% endblock %}</title> <title> {% block title %} Title {% endblock %}</title>
</head> </head>
<div id = "main">
<body>
<h1>
{% block header %} Header {% endblock %}
</h1>
<h1> <div id = "content">
{% block header %} Header {% endblock %} {% block content %} Content {% endblock %}
</h1> </div>
<div id = "navbar">
<body> {% block navbar %} Navigation bar {% endblock %}
{% block content %} Content {% endblock %} </div>
</body> </body>
</div>
</html> </html>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment