check for empty source in dc
[wolnelektury.git] / wolnelektury / templates / base.html
1 <!DOCTYPE html>
2 <html>
3         {% load cache compressed i18n %}
4     {% load catalogue_tags reporting_stats sponsor_tags %}
5     <head>
6         <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
7         <meta name="description" 
8             content="{% block metadescription %}Darmowe opracowane, pełne teksty lektur, e-booki, audiobooki i pliki DAISY na wolnej licencji.{% endblock %}" />
9         <title>{% block title %}{% trans "Wolne Lektury" %} :: 
10             {% block titleextra %}{% endblock %}{% endblock %}</title>
11         <link rel="icon" href="{{ STATIC_URL }}img/favicon.png" type="image/png" />
12         <link rel="search" type="application/opensearchdescription+xml" title="Wolne Lektury" href="{{ STATIC_URL }}opensearch.xml" />
13         {% compressed_css "all" %}
14
15         {% block extrahead %}
16         {% endblock %}
17     </head>
18     <body id="{% block bodyid %}base{% endblock %}">
19
20         {% block bodycontent %}
21
22         <div id="header">
23
24         <div id="header-content">
25             <div id="logo">
26                 <a class="logo" href="/">
27                 Wolne Lektury</a>
28             </div>
29
30             <div id="tagline">
31                 <span>
32                 {% cache 60 tagline LANGUAGE_CODE %}
33                     {% url book_list as b %}
34                     {% url infopage 'o-projekcie' as r %}
35                         {% count_books book_count %}
36                     {% blocktrans count book_count as c %}
37                     <a href='{{b}}'>{{c}}</a> free reading you have <a href='{{r}}'>right to</a>
38                     {% plural %}
39                     <a href='{{b}}'>{{c}}</a> free readings you have <a href='{{r}}'>right to</a>
40                     {% endblocktrans %}
41                 {% endcache %}
42                 </span>
43             </div>
44
45             <p id="user-info" class="mono">
46                 {% if user.is_authenticated %}
47                     {% trans "Welcome" %}, <strong>{{ user.username }}</strong>
48                     | <a href="{% url social_my_shelf %}" id="user-shelves-link">{% trans "My shelf" %}</a>
49                     {% if user.is_staff %}
50                     | <a href="/admin/">{% trans "Administration" %}</a>
51                     {% endif %}
52                     | <a href="{% url logout %}?next={% block logout %}{{ request.get_full_path }}{% endblock %}">{% trans "Logout" %}</a>
53                 {% else %}
54                     <a href="{% url login %}?next={{ request.path }}"
55                         id="login" class="ajaxable">
56                             {% trans "Sign in" %}</a>
57                     /
58                     <a href="{% url register %}?next={{ request.path }}"
59                         id="register" class="ajaxable">
60                             {% trans "Register" %}</a>
61                 {% endif %}
62             </p>
63
64
65             <div class="clearboth"></div>
66
67         </div>
68         </div>
69
70         <div id="half-header">
71         <div id="half-header-content">
72
73
74
75             <form id="search-area" action="/fullsearch/" class="hidelabels">
76                 
77                 <div id="search-field" class="grid-line">
78                         <label for="search">{{search_form.q.label}}</label>
79                   {{search_form.q}}
80 <!--                    <input title="np. Leśmian" name="q" autocomplete="off" data-source="/fullsearch/hint/">-->
81                 </div><div id="search-button">
82                     <button type='submit'><span class="mono">{% trans "Search" %}</span></button>
83                 </div>
84                 
85                 <div class="clearboth"></div>
86             </form>
87
88
89
90         </div>
91         </div>
92
93
94
95         <div id="main-content">
96
97             <div id="nav-line">
98                 {% cache 60 catalogue-menu LANGUAGE_CODE %}
99                         {% catalogue_menu %}
100                 {% endcache %}
101
102             <form action="{% url django.views.i18n.set_language %}" method="post">
103             <div id="lang-menu">
104                 <span id='lang-button' class='mono'>
105                     {% trans "Language versions" %}</span>
106                 <div id="lang-menu-items">
107                 {% for lang in LANGUAGES %}
108                     <button type="submit" name="language"
109                         class="{% ifequal lang.0 LANGUAGE_CODE %}active{% endifequal %} mono"
110                         value="{{ lang.0 }}">{{ lang.1 }}</button>
111                 {% endfor %}
112                 </div>
113             </div>
114             </form>
115             </div>
116
117             <div class="clearboth"></div>
118
119
120
121             {% block body %}
122             {% endblock %}
123
124
125
126
127         <div class="clearboth"></div>
128
129         </div>{# end main-content #}
130
131
132         <div id="footer">
133         <div id="footer-content">
134             <p>
135                 {% blocktrans %}
136                                 Wolne Lektury is a project lead by <a href="http://nowoczesnapolska.org.pl/">Modern Poland Foundation</a>.
137                                 Digital reproductions are made by <a href="http://www.bn.org.pl/">The National Library</a>, <a href="http://www.bs.katowice.pl/">Biblioteka Śląska</a> and <a href="http://www.bibliotekaelblaska.pl/">Biblioteka Elbląska</a>, based on TNL, BŚ and BE resources.
138                                 Hosting: <a href="http://www.icm.edu.pl/">ICM</a>.
139                                 {% endblocktrans %}
140             </p>
141             <p>
142                 {% blocktrans %}
143                                 Modern Poland Foundation, 00-514 Warsaw, ul. Marszałkowska 84/92 lok. 125, tel/fax: (22) 621-30-17
144                 e-mail: <a href="mailto:fundacja@nowoczesnapolska.org.pl">fundacja@nowoczesnapolska.org.pl</a>
145                                 {% endblocktrans %}
146             </p>
147
148             {% block add_footer %}{% endblock %}
149
150                         {% sponsor_page "footer" %}
151         </div>
152         </div>
153
154
155
156         {# template #}
157         <div id="ajaxable-window" class='dialog-window'>
158             <div class="header mono"><a href="#" class="jqmClose">{% trans "Close" %}</a></div>
159             <div class="target">
160                 <p><img src="{{ STATIC_URL }}img/indicator.gif" alt="*"/> {% trans "Loading" %}</p>
161             </div>
162         </div>
163
164
165         {% endblock bodycontent %}
166
167
168         <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
169         <script type="text/javascript">
170             var LANGUAGE_CODE = "{{ LANGUAGE_CODE }}";
171             var STATIC_URL = "{{ STATIC_URL }}";
172         </script>
173         {% compressed_js "base" %}
174
175         <!--{{ piwik_tag|safe }}
176         <script type="text/javascript">
177         var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
178         document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
179         </script>
180         <script type="text/javascript">
181         var pageTracker = _gat._getTracker("UA-2576694-1");
182         pageTracker._trackPageview();
183         </script>-->
184     </body>
185 </html>