Massive changes. Added long-polling support
[flowspy] / templates / base.html
1 {% load i18n %}
2 <html>
3 <head>
4 <title>GRNET's FoD :: {% block title %}{% endblock %} </title>
5 <META HTTP-EQUIV="Pragma" CONTENT="no-cache">
6 <META HTTP-EQUIV="Expires" CONTENT="-1">
7 <script src="/static/js/jquery.min.js" type="text/javascript"></script>
8 <link rel="stylesheet" type="text/css" href="/static/css/base.css">
9 <link rel="stylesheet" type="text/css" href="/static/css/smoothness/jquery-ui-1.8.13.custom.css">
10 <script type="text/javascript" src="/static/js/jquery-ui-1.8.12.custom.min.js"></script>
11 <script type="text/javascript" src="/static/js/poller.js"></script>
12 <script type="text/javascript">
13
14         function setlang(lang){
15                 $("#langsel").val(lang);
16                 $("#langform").submit();
17         }
18
19 //function highlight(elemId){
20 //    var elem = $(elemId);
21 //    elem.css("background-color", "#ffffbb");
22 //    setTimeout(function() { $(elemId).animate({ backgroundColor: "white" }, 2000)}, 1500);
23 //}
24 //
25 //   
26 //$(document).ready( function(){
27 //      if (document.location.hash) {
28 //          highlight(document.location.hash);
29 //      }
30 //      $('a[href*=#]').click(function(){
31 //          var elemId = '#' + $(this).attr('href').split('#')[1];
32 //          highlight(elemId);
33 //      });
34 //});
35
36 </script>
37 {% block extrahead %}{% endblock %}
38 </head>
39
40
41
42 <body>
43         <div id="main">
44                         <div id="header">
45                                 <a class="grnetlogo" href="/">
46                                         <img class="logoimg" src="/static/grnet_logo.png">
47                                 </a>
48                                 <div id="title">
49                                         <a href="/">Firewall on Demand</a>
50                                 </div>
51                                 <div class="loginform">
52                                         <div id="formcontent">
53                                                 {% if user.is_authenticated %}
54                                                 <span class="topmenuuser">{% trans "Welcome" %} <strong>{{user}}</strong></span>
55                                                 {% endif %}
56                                                 <span {% if user.is_authenticated %}class="topmenuaction"{% else %}class="topmenuuser"{% endif %} >
57                                                         <form action="{% url django.views.i18n.set_language %}" method="post" style="display:inline;" id="langform">
58                                                                 {% csrf_token %}
59                                                                 <input name="next" type="hidden" value="{{ next }}" />
60                                                                 <input id="langsel" name="language" type="hidden" value="" />
61                                                                 {% for lang in LANGUAGES %}<a class="select_lang" href="#" onclick="setlang('{{ lang.0 }}'); return false;" title="{{lang.1}}">{% ifnotequal LANGUAGE_CODE lang.0 %}<font style="font-weight:normal;">{% endifnotequal %}{% trans lang.1 %}{% ifnotequal LANGUAGE_CODE lang.0 %}</font>{% endifnotequal %}</a>{% if not forloop.last %} -{% endif %}
62                                                                 {% endfor %}
63                                                         </form>
64                                                 </span>
65                                                 {% if user.is_authenticated %}
66                                                 <span class="topmenuaction"><a href="">{% trans "My profile" %}</a></span>
67 {% if user.is_superuser %}
68                                                 <span class="topmenuaction"><a href="{% url admin:index %}">{% trans "Admin" %}</a></span>
69 {% endif %}
70                                                 <span class="topmenuaction"><a href="{% url logout %}">{% trans "Logout" %}</a></span>
71                                                 {% else %}
72                                                 <span class="topmenuaction"><a href="{% url login %}">{% trans "Login" %}</a></span>
73                                                 {% endif %}
74                                         </div>
75                                         
76                                 </div>
77                         </div>
78                         <div id="content">
79                                 {% block brcrmb_container %}
80                                 <div class="info_content_title">{% if user.is_authenticated %}<a href="/">{% trans "My routes" %}</a>{% endif %}
81                                 {% block breadcrumbs %}{% endblock %}
82                                 </div>
83                                 
84                                 {% endblock %}
85                                 {% block content %}
86                                 {% endblock %}
87
88                         </div>
89                         <div id="footer">
90                         {% if user.is_authenticated %}
91                         {% trans "If you have any questions or need help, contact GRNET Helpdesk at <a href='mailto:helpdesk@grnet.gr'>helpdesk@grnet.gr</a> or 800-11-47638." %}<br />
92                         {% endif %}
93                         <a href="http://www.grnet.gr">{% trans "GRNET" %} NOC</a> | <a href="/about/info/">{% trans "Info" %}</a> | <a href="/about/terms-of-service">{% trans "Service Terms" %}</a>
94                         </div>
95         </div>
96 </body>
97 </html>