]> git.openstreetmap.org Git - osqa.git/blob - forum/skins/default/templates/base_content.html
OSQA-266
[osqa.git] / forum / skins / default / templates / base_content.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2 <!-- base_content.html -->
3 {% load i18n extra_tags extra_filters markup ui_registry %}
4 <html xmlns="http://www.w3.org/1999/xhtml">
5     <head>
6         <title>{% block fulltitle %}{% block title %}{% endblock %} - {{ settings.APP_SHORT_NAME }}{% endblock %}</title>
7         <meta name="description" content="{% block metadescription %}{{ settings.APP_DESCRIPTION }}{% endblock %}">
8         <meta name="keywords" content="{% block metakeywords %}{{ settings.APP_KEYWORDS }}{% endblock %}">
9         {% block meta %}{% endblock %}
10         <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
11         {% if settings.GOOGLE_SITEMAP_CODE %}
12         <meta name="google-site-verification" content="{{ settings.GOOGLE_SITEMAP_CODE }}" />
13         {% endif %}
14         <link rel="shortcut icon" href="{{ settings.APP_FAVICON }}" />
15         <link href="{% media  "/media/style/style.css" %}" rel="stylesheet" type="text/css" />
16         {% if settings.USE_CUSTOM_CSS|or_preview:request %}
17         <link href="{% url custom_css %}" rel="stylesheet" type="text/css" />
18         {% endif %}
19         {% block forestyle %}{% endblock %}
20         <script src="http://www.google.com/jsapi" type="text/javascript"></script>
21         <script type="text/javascript">google.load("jquery", "1.4.2");</script>
22         <script type="text/javascript">
23         /* <![CDATA[ */
24             var i18nLang = '{{settings.LANGUAGE_CODE}}';
25             var scriptUrl = '/{{settings.FORUM_SCRIPT_ALIAS}}'
26             var osqaSkin = '{{settings.OSQA_SKIN}}';
27
28             var messages = {
29                 username: '{{ user.username }}',
30                 confirm: "{% trans "Are you sure?" %}",
31                 yes: "{% trans "Yes" %}",
32                 no: "{% trans "No" %}",
33                 message: "{% trans "Message:" %}",
34                 cancel: "{% trans "Cancel" %}",
35                 close: "{% trans "Close" %}",
36                 ok: "{% trans "Ok" %}",
37                 matching_tags_url: "{% url matching_tags %}"
38             }
39         /* ]] */
40         </script>
41         <script type='text/javascript' src='{% media  "/media/js/osqa.main.js" %}'></script>
42         {% if user_messages %}
43         <style type="text/css">
44             body { margin-top:2.4em; }
45         </style>
46         <script type="text/javascript">
47             $(document).ready(function() {
48                 var element = $('#validate_email_alert');
49                 element.click(function(){notify.close(true);})
50                 notify.show();
51             });
52         </script>
53         {% endif %}
54         {% if settings.USE_CUSTOM_HEAD|or_preview:request %}
55             {{ settings.CUSTOM_HEAD|or_preview:request|safe }}
56         {% endif %}
57         {% block forejs %}{% endblock %}
58         <link rel="search" type="application/opensearchdescription+xml" href="{% url opensearch %}" title="{{ settings.APP_SHORT_NAME }} Search" />
59         {% loadregistry head_content %}{% endloadregistry %}
60     </head>
61     <body>
62         <div class="notify" style="display:none">
63             {% autoescape off %}
64                 {% if user_messages %}
65                     {% for message in user_messages %}
66                           <p class="darkred">{{ message }}</p>
67                     {% endfor %}
68                 {% endif %}
69             {% endautoescape %}
70             <a id="close-notify" onclick="notify.close(true)">&times;</a>
71         </div>
72         {% if settings.USE_CUSTOM_HEADER|or_preview:request %}
73             <div id="custom_header">
74                 {{ settings.CUSTOM_HEADER|or_preview:request|markdown:"settingsparser" }}    
75             </div>
76         {% endif %}
77         {% include "header.html" %}
78         {% block page_center %}
79         <div id="wrapper">
80             <div id="room">
81                 <div id="CAFull">
82                     {% block content%}
83                     {% endblock%}
84
85                 </div>
86                 <div id="tail" style="clear:both;">
87                     {% block tail %}
88                     {% endblock %}
89                 </div>
90             </div>
91             <div class="spacer3"></div>
92         </div>
93         {% endblock %}
94         {% if settings.USE_CUSTOM_FOOTER|or_preview:request %}
95             {% ifequal settings.CUSTOM_FOOTER_MODE|or_preview:request "above" %}
96                 <div id="custom_footer">
97                     {{ settings.CUSTOM_FOOTER|or_preview:request|markdown:"settingsparser" }}
98                 </div>
99             {% endifequal %}
100             <div id="ground">
101                 {% ifequal settings.CUSTOM_FOOTER_MODE|or_preview:request "replace" %}
102                     {{ settings.CUSTOM_FOOTER|or_preview:request|markdown:"settingsparser" }}
103                 {% else %}
104                     {% include "footer.html" %}
105                 {% endifequal %}
106             </div>
107             {% ifequal settings.CUSTOM_FOOTER_MODE|or_preview:request "below" %}
108                 <div id="custom_footer">
109                     {{ settings.CUSTOM_FOOTER|or_preview:request|markdown:"settingsparser" }}
110                 </div>
111             {% endifequal %}
112         {% else %}
113             <div id="ground">
114                 {% include "footer.html" %}
115             </div>
116         {% endif %}
117         {% block endjs %}
118         {% endblock %}
119         {% if settings.GOOGLE_ANALYTICS_KEY %}
120             <script type="text/javascript">
121                 var _gaq = _gaq || [];
122                 _gaq.push(['_setAccount', '{{ settings.GOOGLE_ANALYTICS_KEY }}']);
123                 _gaq.push(['_trackPageview']);
124
125                 (function() {
126                     var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
127                     ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
128                     var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
129                 })();
130             </script>
131         {% endif %}
132     </body>
133 </html>
134 <!-- end template base_content.html -->