incubator-ooo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From w...@apache.org
Subject svn commit: r1365385 - in /incubator/ooo/ooo-site/trunk: lib/view.pm templates/skeleton.html
Date Wed, 25 Jul 2012 01:16:11 GMT
Author: wave
Date: Wed Jul 25 01:16:11 2012
New Revision: 1365385

URL: http://svn.apache.org/viewvc?rev=1365385&view=rev
Log:
(1) Change header to head to avoid confusion with headers. (2) Properly include bodytag in
template.

Modified:
    incubator/ooo/ooo-site/trunk/lib/view.pm
    incubator/ooo/ooo-site/trunk/templates/skeleton.html

Modified: incubator/ooo/ooo-site/trunk/lib/view.pm
URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/lib/view.pm?rev=1365385&r1=1365384&r2=1365385&view=diff
==============================================================================
--- incubator/ooo/ooo-site/trunk/lib/view.pm (original)
+++ incubator/ooo/ooo-site/trunk/lib/view.pm Wed Jul 25 01:16:11 2012
@@ -93,7 +93,7 @@ sub html_page {
     read_text_file $ssi_header_file, $args{ssi};
 
     if ($args{content} =~ m!<head.*?>(.*?)</head>(?:.*?<body(.*?)>)?(.*?)(?:</body>|\Z)!si)
{
-        @args{qw/header bodytag content/} = ($1, $2, $3);
+        @args{qw/head bodytag content/} = ($1, $2, $3);
     }
 
     $args{breadcrumbs} =~ s/home/$args{ssi}{headers}{home}/;

Modified: incubator/ooo/ooo-site/trunk/templates/skeleton.html
URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/templates/skeleton.html?rev=1365385&r1=1365384&r2=1365385&view=diff
==============================================================================
--- incubator/ooo/ooo-site/trunk/templates/skeleton.html (original)
+++ incubator/ooo/ooo-site/trunk/templates/skeleton.html Wed Jul 25 01:16:11 2012
@@ -2,19 +2,18 @@
 <html>
 <head>
 <link href="/css/ooo.css" rel="stylesheet" type="text/css">
-{% if header %}
-{% autoescape off %}{{ header }}{% endautoescape %}{% else %}
+{% if head %}{{ head|safe }}{% else %}
 <title>{% block title %}{{ headers.title }}{% endblock %}</title>
 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
 {% if headers.css %}<link href="{{ headers.css }}" rel="stylesheet" type="text/css">{%
endif %}
 {% endif %}
 <!--#include virtual="/google-analytics.js" -->
 </head>
-<body>
+<body{% if bodytag %} {{ bodytag|safe }}{% endif %}>
 <!--#include virtual="{{ ssi.headers.brand }}" -->
   <div id="topbara">
     {% if ssi.headers.topnav %}<!--#include virtual="{{ ssi.headers.topnav }}" -->{%
endif %}
-    <div id="breadcrumbsa">{% block breaddcrumbs %}{% autoescape off %}{{ breadcrumbs
}}{% endautoescape %}{% endblock %}</div>
+    <div id="breadcrumbsa">{% block breaddcrumbs %}{{ breadcrumbs|safe }}{% endblock
%}</div>
   </div>
   <div id="clear"></div>
   {% if ssi.headers.leftnav %}<!--#include virtual="{{ ssi.headers.leftnav }}" -->{%
endif %}
@@ -24,8 +23,6 @@
     {% block title %}{% if headers.title %}<h1 class="title">{{ headers.title }}</h1>{%
endif %}{% endblock %}
     {% block content %}{{ content|markdown }}{% endblock %}
   </div>
-
 <!--#include virtual="{{ ssi.headers.footer }}" -->
-
 </body>
 </html>



Mime
View raw message