Parcourir la source

Enclose strings used in Jinja in single quotes

Talha Mansoor il y a 11 ans
Parent
commit
5d5e48d15f

+ 1 - 1
templates/404.html

@@ -1,4 +1,4 @@
-{% extends "base.html" %}
+{% extends 'base.html' %}
 
 {% block title %}
 Page not found · {{ super() }}

+ 2 - 1
templates/archives.html

@@ -1,4 +1,5 @@
-{% extends "base.html" %}                                                                                                                                                                                  
+{% extends 'base.html' %}
+
 {% block title %}
 All Posts · {{ super() }}
 {% endblock title %}

+ 6 - 6
templates/article.html

@@ -1,4 +1,4 @@
-{% extends "base.html" %}
+{% extends 'base.html' %}
 
 {% block title %}
 {{ article.title }} {%if article.subtitle %} - {{ article.subtitle }} {% endif %} · {{ super() }}
@@ -56,8 +56,8 @@
                 {% set ptitle = previous_article.title %}
                 {% set pv_title = ptitle %}
                     {%if previous_article.subtitle %} 
-                        {% set pv_title = ptitle + " " +  "<small>" + previous_article.subtitle + "</small>" %}
-                        {% set ptitle = ptitle + " - " + previous_article.subtitle %}
+                        {% set pv_title = ptitle + ' ' +  '<small>' + previous_article.subtitle + '</small>' %}
+                        {% set ptitle = ptitle + ' - ' + previous_article.subtitle %}
                     {% endif %} 
                 <li class="previous_article">« <a href="{{ SITEURL }}/{{ previous_article.url }}" title="Previous: {{ ptitle }}">{{ pv_title }}</a></li>
                 {% endif %}
@@ -65,8 +65,8 @@
                 {% set ntitle = next_article.title %}
                 {% set nv_title = ntitle %}
                     {%if next_article.subtitle %} 
-                        {% set nv_title = ntitle + " " +  "<small>" + next_article.subtitle + "</small>" %}
-                        {% set ntitle = ntitle + " - " + next_article.subtitle %}
+                        {% set nv_title = ntitle + ' ' +  '<small>' + next_article.subtitle + '</small>' %}
+                        {% set ntitle = ntitle + ' - ' + next_article.subtitle %}
                     {% endif %} 
                 <li class="next_article"><a href="{{ SITEURL }}/{{ next_article.url }}" title="Next: {{ ntitle }}">{{ nv_title }}</a> »</li>
                 {% endif %}
@@ -113,7 +113,7 @@
 {% block script %}
     {{ super() }}
     {% include 'disqus_script_count.html' %}
-    {% if DISQUS_SITENAME and SITEURL and article.status != "draft" %}
+    {% if DISQUS_SITENAME and SITEURL and article.status != 'draft' %}
         <script  language="javascript" type="text/javascript">
             function uncollapse() {
                 var hash_str = window.location.hash;

+ 4 - 4
templates/base.html

@@ -55,15 +55,15 @@
                     <a class="brand" href="{{ SITEURL }}/"><span class=site-name>{{ SITENAME }}</span></a>
                     <div class="nav-collapse collapse">
                         <ul class="nav pull-right top-menu">
-                            <li {% if page_name == "index" %} class="active"{% endif %}><a href="{{ SITEURL }}">Home</a></li>
+                            <li {% if page_name == 'index' %} class="active"{% endif %}><a href="{{ SITEURL }}">Home</a></li>
                             {% if DISPLAY_PAGES_ON_MENU %}
                             {% for page in pages %}
                             <li {% if output_file == page.url %} class="active"{% endif %}><a href="{{ SITEURL }}/{{ page.url }}">{{ page.title }}</a></li>
                             {% endfor %}
                             {% endif %}
-                            <li {% if page_name == "categories" %} class="active"{% endif %}><a href="{{ SITEURL }}/categories.html">Categories</a></li>
-                            <li {% if page_name == "tags" %} class="active"{% endif %}><a href="{{ SITEURL }}/tags.html">Tags</a></li>
-                            <li {% if page_name == "archives" %} class="active"{% endif %}><a href="{{ SITEURL }}/archives.html">Archives</a></li>
+                            <li {% if page_name == 'categories' %} class="active"{% endif %}><a href="{{ SITEURL }}/categories.html">Categories</a></li>
+                            <li {% if page_name == 'tags' %} class="active"{% endif %}><a href="{{ SITEURL }}/tags.html">Tags</a></li>
+                            <li {% if page_name == 'archives' %} class="active"{% endif %}><a href="{{ SITEURL }}/archives.html">Archives</a></li>
                             <li><form class="navbar-search" action="{{ SITEURL }}/search.html" onsubmit="return validateForm(this.elements['q'].value);"> <input type="text" class="search-query" placeholder="Search" name="q" id="tipue_search_input"></form></li>
                         </ul>
                     </div>

+ 1 - 1
templates/categories.html

@@ -1,4 +1,4 @@
-{% extends "base.html" %}
+{% extends 'base.html' %}
 
 {% block title %}
 All Categories · {{ super() }}

+ 1 - 1
templates/comments.html

@@ -1,4 +1,4 @@
-{% if DISQUS_SITENAME and SITEURL and article.status != "draft" %}
+{% if DISQUS_SITENAME and SITEURL and article.status != 'draft' %}
 <section>
 {% if COMMENTS_INTRO %}
 <p id="comment-message">{{ COMMENTS_INTRO }} </p>

+ 1 - 1
templates/disqus_script_count.html

@@ -1,4 +1,4 @@
-{% if DISQUS_SITENAME and SITEURL and article.status != "draft" %}
+{% if DISQUS_SITENAME and SITEURL and article.status != 'draft' %}
 <script type="text/javascript">
     var disqus_shortname = '{{ DISQUS_SITENAME }}';
 

+ 1 - 1
templates/index.html

@@ -1,4 +1,4 @@
-{% extends "base.html" %}
+{% extends 'base.html' %}
 
 {% block title %}
 {{ super() }}

+ 1 - 1
templates/page.html

@@ -1,4 +1,4 @@
-{% extends "base.html" %}
+{% extends 'base.html' %}
 
 {% block title %}
 {{ page.title }} {%if page.subtitle %} - {{ page.subtitle }} {% endif %} · {{ super() }}

+ 1 - 1
templates/search.html

@@ -1,4 +1,4 @@
-{% extends "base.html" %}
+{% extends 'base.html' %}
 
 {% block title %}
 Search · {{ super() }}

+ 1 - 1
templates/tags.html

@@ -1,4 +1,4 @@
-{% extends "base.html" %}
+{% extends 'base.html' %}
 
 {% block title %}
 All Tags · {{ super() }}