changeset 228:694acf75447f

Fix HTML to make it W3C valid.
author Daniele Nicolodi <daniele@grinta.net>
date Thu, 24 Nov 2011 17:31:32 +0100
parents b9f7aac3fd06
children 32fda28194d6
files src/ltpdarepo/static/style.css src/ltpdarepo/templates/layout.html src/ltpdarepo/templates/objs.html
diffstat 3 files changed, 13 insertions(+), 15 deletions(-) [+]
line wrap: on
line diff
--- a/src/ltpdarepo/static/style.css	Thu Nov 24 17:31:30 2011 +0100
+++ b/src/ltpdarepo/static/style.css	Thu Nov 24 17:31:32 2011 +0100
@@ -79,11 +79,13 @@
     -webkit-box-shadow: -4px 2px 4px rgba(0, 0, 0, 0.4);
 }
 
+.header .content {
+    padding: 0.75em 0;
+}
+
 .header a {
-    display: block;
     text-decoration: none;
     color: inherit;
-    padding: 0.25em 0;
 }
 
 .header h1 {
@@ -118,8 +120,8 @@
 }
 
 .footer {
-    margin: 9em 9em 2em 9em;
-    padding: 0.25em 1em;
+    margin: 9em 9em 0 9em;
+    padding: 0.25em 1em 2em 1em;
     color: #888;
     border-top: 1px solid #AAA;
 }
--- a/src/ltpdarepo/templates/layout.html	Thu Nov 24 17:31:30 2011 +0100
+++ b/src/ltpdarepo/templates/layout.html	Thu Nov 24 17:31:32 2011 +0100
@@ -1,8 +1,7 @@
-<!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">
+<!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>
+    <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
     <title>{% block title %} {% endblock %} &mdash; LTPDA Repository</title>
     <link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='style.css') }}" />
     {%- block head %}{% endblock -%}
@@ -11,10 +10,8 @@
 
     <div class="header">
       <div class="content">
-        <a href="{{ url_for('index') }}">
-          <h1>LTPDA Repository</h1>
-          <span>{{ request.host }}</span>
-        </a>
+        <h1><a href="{{ url_for('index') }}">LTPDA Repository</a></h1>
+        <span>{{ request.host }}</span>
       </div>
     </div>
 
@@ -45,7 +42,6 @@
       <p><a href="http://www.gnu.org/licenses/agpl.html">AGPLv3</a> &mdash;
          <a href="http://dev.grinta.net/hg/ltpdarepo/">Dowload source code</a></p>
       <p>Version {{ g.version }} &mdash; Database schema {{ g.schema }}</p>
-      <p></p>
     </div>
 
   </body>
--- a/src/ltpdarepo/templates/objs.html	Thu Nov 24 17:31:30 2011 +0100
+++ b/src/ltpdarepo/templates/objs.html	Thu Nov 24 17:31:32 2011 +0100
@@ -25,8 +25,8 @@
   </thead>
   <tbody>
     {% for obj in objs %}
-    <tr class="data {{ loop.cycle('odd', 'even') }}" id="{{ loop.index }}">
-      {% for field in fields %}      
+    <tr class="data {{ loop.cycle('odd', 'even') }}">
+      {% for field in fields %}
       {% if field in ('id', 'name') %}
       <td class="{{ field }}"><a href="{{ url_for('browse.obj', database=database.id, objid=obj.id) }}">{{ obj[field] }}</a></td>
       {% else %}