Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {% extends 'layout.html' %}
- {% load static from staticfiles %}
- {% block title %} {{ book.title }} {% endblock %}
- {% block content %}
- {% include 'payments/quantityForm.html' %}
- <!--htmlCode = "-->
- <!DOCTYPE html>
- <html>
- <head>
- <meta content="text/html; charset=ISO-8859-1" http-equiv="content-type">
- <title>{{ titleName }}</title>
- <style>
- .header-bar {
- background-color: rgb(150,150,150);
- border: 3px solid black;
- width: 80%;
- padding: 5px;
- }
- .comment-bar {
- background-color: rgb(150,150,150);
- border: 3px solid black;
- width: 80%;
- padding: 5px;
- }
- .descriptor {
- font-weight: bold;
- }
- .descriptor-bar {
- min-height: 200px;
- }
- .title-text {
- color: white;
- }
- .commentBlock {
- margin-left: 15px;
- width: 95%;
- border: 3px solid blue;
- font-style: italics;
- }
- .right-align {
- text-align: right;
- }
- .comment-Text-Area {
- align-content:center;
- }
- #cover-img {
- float: right;
- margin-left: 10px;
- width: 200px;
- border: 3px solid red;
- }
- .inlineDiv {
- display: inline;
- }
- </style>
- </head>
- <body>
- <div class="header-bar">
- <div>
- <span class="descriptor">Title:</span><span class="title-text">{{ book.title }}</span><br>
- <span class="descriptor">Author:</span>{{ book.author.first_name }} {{book.author.last_name }}<br>
- <span class="descriptor">Genre:</span>{{ book.genre }}<br>
- </div>
- <div class="inlineDiv">
- <span class="descriptor">Rating:</span>{{ book.rating }}<br>
- <span class="descriptor">Price:</span>${{ book.Price }}<br></div>
- <div class="inlineDiv"><img id="cover-img" src="{% static book.cover_file_name %}"/></div>
- </div>
- <br>
- <div class="header-bar descriptor-bar">
- <span class="descriptor">Description:</span><br>{{ book.description }}
- </div>
- <br>
- <!--
- #append to Code 1 for every comment.
- htmlCode2 = "-->
- <br>
- <div class="header-bar">
- {% if userName %}
- <form method="get">
- <textarea class="comment-Text-Area" name="newComment" rows="4" cols="50">
- Write a review.
- </textarea>
- <br><input type="submit" value="submit">
- </form>
- {% else %}
- <h4>Please Loging to leave a comment.</h4>
- {% endif %}
- </div>
- {% for review in tuple %}
- <div class="header-bar">
- <span class="descriptor">]]userName wrote:<span>
- <br>
- <div class="commentBlock">
- "
- <br>
- {{comment}}
- <br>
- <span class="right-align">"</span>
- </div>
- </div>
- {% endfor %}
- {% if not tuple %}
- <div class="header-bar">
- <span class="descriptor">]]userName wrote:<span>
- <br>
- <div class="commentBlock">
- "
- <br>
- {{comment}}
- <br>
- <span class="right-align">"</span>
- </div>
- </div>
- {% endif %}
- <!--#append to Code 1-->
- </body>
- </html>
- <!--end HTML Tag-->
- <!--
- <form action="/action_page.php" method="post" target="_blank">
- First name: <input type="text" name="fname"><br>
- Last name: <input type="text" name="lname"><br>
- <input type="submit" value="Submit">
- </form>
- <p>Click on the submit button, and the input will be sent to a page on the server called "/action_page.php".</p>
- -->
- {% endblock %}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement