Proper logged in/out message styles
[snf-cloudcms] / cloudcms / templates / cms / base.html
1 <!doctype html>
2 {% load feincms_tags feincms_page_tags %}
3
4 <head>
5   <title>
6       {% block page.title %}{% if feincms_page.page_title %}{{ feincms_page.page_title }}
7       {% else %}{{ feincms_page.title }}{% endif %} | {{ APP.title }}{% endblock %}
8   </title>
9   <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
10   <meta name="viewport" content="width=device-width, initial-scale=1.0,minimum-scale=1.0, maximum-scale=1.0">  
11   
12   {% block favicons %}
13   <link rel="shortcut icon" href="{{ APP.favicon.get_absolute_url }}">
14   <link rel="apple-touch-icon" href="{{ APP.favicon.get_absolute_url }}">
15   {% endblock favicons %}
16
17   {% block css %}
18       
19       <link href='https://fonts.googleapis.com/css?family=Open+Sans:400,600,700&subset=latin,greek-ext,greek' rel='stylesheet' type='text/css'>
20       <link rel="stylesheet" type="text/css" href="{{ MEDIA_URL }}cloudcms/css/global.css">
21       <link rel="stylesheet" type="text/css" href="{{ MEDIA_URL }}cloudcms/css/print.css" media="print">
22       <!--[if lte IE 7]>
23           <link rel="stylesheet" type="text/css" href="{{ MEDIA_URL }}cloudcms/css/ie7.css">
24       <![endif]-->
25       <link rel="stylesheet" media="screen and (max-width: 960px)" href="{{ MEDIA_URL }}cloudcms/css/max960.css"/>
26       <link rel="stylesheet" media="screen and (max-width: 768px)" href="{{ MEDIA_URL }}cloudcms/css/max768.css"/>
27       <link rel="stylesheet" media="screen and (max-width: 480px)" href="{{ MEDIA_URL }}cloudcms/css/max480.css"/>  
28   {% endblock css %}
29
30   {% block headjs %}
31       <script src="https://www.youtube.com/iframe_api"></script>
32       <script src="{{ MEDIA_URL }}cloudcms/js/jquery-1.7.1.min.js"></script>
33       <script src="{{ MEDIA_URL }}cloudcms/js/underscore.js"></script>
34       <script src="{{ MEDIA_URL }}cloudcms/js/jquery.infieldlabel.js"></script>
35       <script src="{{ MEDIA_URL }}cloudcms/js/jquery.colorbox.js"></script>
36       <script src="{{ MEDIA_URL }}cloudcms/js/jquery.dropkick-1.0.0.js"></script>
37       <script src="{{ MEDIA_URL }}cloudcms/js/jquery.tablesorter.js"></script>
38       <script src="{{ MEDIA_URL }}cloudcms/js/common.js"></script>
39       <script src="{{ MEDIA_URL }}cloudcms/js/forms.js"></script>
40       <script src="{{ MEDIA_URL }}cloudcms/js/os.js"></script>
41       <script src="{{ MEDIA_URL }}cloudcms/js/jquery-ui-1.8.21.custom.min.js"></script>
42       <script src="{{ MEDIA_URL }}cloudcms/js/resources_list.js"></script> 
43   {% endblock headjs %}
44
45   {% block page.cms.media %}
46   {{ feincms_page.content.media }}
47   {% endblock %}
48
49   {% block page.scripts.cloudbar %}
50       {% if CLOUDBAR_ACTIVE %} {{ CLOUDBAR_CODE }} {% endif %}
51   {% endblock %}
52
53    <script type="text/javascript">
54       $(document).ready(function() {
55           $("form.innerlabels label").inFieldLabels();
56           $("form .form-row").formErrors();
57       })
58    </script>
59   {% block endhead %}{% endblock endhead %}
60
61   <style type="text/css">
62   {% block extrastyles %}
63   {% endblock %}
64   </style>
65
66   {% if APP.extra_styles %}
67   <style type="text/css">
68       {{ APP.extra_styles|safe }}
69   </style>
70   {% endif %}
71     
72 </head>
73
74 <body>
75     {% block page.mainbody %}
76      
77     <div class="container">
78         <div class="wrapper">
79           {% if APP.message_type != 'NM' %}
80           <div class="top-msg active {{ APP.message_type }}">
81             <div class="msg">
82                 {{ APP.custom_message|safe }}
83               <a href="#" title="close" class="close">X</a>
84             </div>
85           </div>
86           {% endif %}
87                   {% if messages %}
88                           {% for message in messages %}
89               <div class="top-msg active {{ message.tags }}">
90                 <div class="msg">
91                   {{ message }}
92               <a href="#" title="close" class="close">X</a>
93                 </div>
94               </div>
95                           {% endfor %}
96                   </ul>
97                   {% endif %}
98                 <div class="mainlogo">
99                         {% if APP.logo %}
100                                 <h1>
101                                     <a href="{{ APP.index_url }}" title="{{ APP.title }}">
102                                         <img src="{{ APP.logo.get_absolute_url }}" alt="{{ APP.title }}" />
103                                     </a>
104                                 </h1>
105                         {% else %}
106                             <h1>{{ APP.title }}</h1>
107                         {% endif %}
108                     </div>
109                 <div class="navigation">
110               {% if feincms_page.featured and APP.accounts_url %}
111                   <a class="prompt" href="{{ APP.accounts_url }}">create an account now ></a>
112               {% endif %}
113                     <ul>
114                         {% block page.nav %}
115                             {% feincms_navigation of feincms_page as sublevel level=2,depth=1 %}
116                             {% for p in sublevel %}
117                             <li class="{% if p|is_equal_or_parent_of:feincms_page %}active{% endif %}">
118                             <a href="{{ p.get_absolute_url }}">{{ p.title }}</a></li>
119                             {% endfor %}
120                         {% endblock %}
121                     </ul>
122                     <ul>
123                         {% block page.subnav %}
124                             {% if feincms_page.override_url != "/" %}
125                             {% feincms_navigation of feincms_page as sublevel level=3,depth=1 %}
126                             {% for p in sublevel %}
127                             <li class="{% if p|is_equal_or_parent_of:feincms_page or p.url == request.path %}active{% endif %}">
128                             <a href="{{ p.get_absolute_url }}">{{ p.title }}</a></li>
129                             {% endfor %}
130                             {% endif %}
131                         {% endblock %}
132                     </ul>
133                 </div>
134                 <div class="content">
135                 {% block page.body %}
136                 {% endblock %}
137                 </div>
138             </div>    
139     </div>
140     
141     <div class="footer">
142         <div class="wrapper">
143                 {% include "cms/footer.html" %}
144         </div>
145     </div>
146     {% endblock page.mainbody %}
147 </body>
148 </html>