{% load i18n %}
{% load wiki %}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head profile="http://gmpg.org/xfn/11">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

    <title>{{ site_name }} - {{ title }}</title>

    <link rel="icon" type="image/png" href="{% url twistranet_home %}static/images/favicon.png" />
    <meta name="generator" content="twistranet" />
    <link rel="stylesheet" href="{% url twistranet_home %}static/css/style.css" type="text/css" media="screen" />
    <link rel="stylesheet" href="{% url twistranet_home %}static/css/login.css" type="text/css" media="screen" />
    <link rel="stylesheet" href="{% url twistranet_home %}static/css/forms.css" type="text/css" media="screen" />
    <link rel="stylesheet" href="{% url twistranet_home %}static/css/content.css" type="text/css" media="screen" />
    <link rel="stylesheet" href="{% url twistranet_home %}static/css/jquery-ui-1.8.5.custom.css" type="text/css" media="screen" />      
    <link rel="stylesheet" href="{% url twistranet_home %}static/css/jquery-dd.css" type="text/css" media="screen" /> 
    <link rel="stylesheet" href="{% url twistranet_home %}static/css/fileuploader.css" type="text/css" media="screen" />
    {% block local_css %}{% endblock %}
    <!--[if lte IE 7]><style type="text/css" media="all">@import url({% url twistranet_home %}static/css/ie7.css);</style><![endif]-->
    <!--[if lte IE 9]><style type="text/css" media="all">@import url({% url twistranet_home %}static/css/ie.css);</style><![endif]-->
    <script type="text/javascript" src="{% url twistranet_home %}static/js/jquery.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_js_vars %}" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/includes/lib/include.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/includes/lib/scrollTo.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/includes/lib/browserdetect.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/includes/lib/hoverIntent.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/includes/lib/superfish.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/includes/mad.jquery.js" charset="utf-8"></script> 
    <script type="text/javascript" src="{% url twistranet_home %}static/js/jquery-ui-1.8.10.custom.min.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/jquery.livesearch.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/jquery.dd.js" charset="utf-8"></script>      
    <script type="text/javascript" src="{% url twistranet_home %}static/js/fileuploader.js" charset="utf-8"></script>  
    <script type="text/javascript" src="{% url twistranet_home %}static/js/tn_quickupload_helpers.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/comments.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/sharing.js" charset="utf-8"></script>
    <script type="text/javascript" src="{% url twistranet_home %}static/js/tn.js" charset="utf-8"></script>
    {% block local_js %}{% endblock %}
    {% if form %}{{ form.media }}{% endif %}
    {% block local_headers %}{% endblock %}
</head>
<body{% if body_class %} class="{{ body_class }}"{% endif %}>
    <div id="page">
        <div id="wrapper">
            <div id="header">
                <div id="head">
                    {% block topbar %}
                    <div id="usermenu">
                        <div class="caption">
                            <ul>
                                {% if user.is_authenticated %}
                                <li>
                                    <a href="{% url twistranet_home %}">{{ current_account.title }}</a>
                                </li>
                                {% endif %}
                                {% block useractions %}
                                {% endblock %}
                                {% if user.is_authenticated %}
                                <li class="last">
                                    <a href="{% url logout %}">{% blocktrans %}Log out{% endblocktrans %}</a>
                                </li>
                                {% else %}
                                <li class="last"><a href="/login">{% blocktrans %}Log in{% endblocktrans %}</a></li>
                                {% endif %}
                            </ul>
                        </div>
                    </div>
                    {% endblock %}
                    <a class="logotext"
                       href="{% url twistranet_home %}">
                        <div class="logo-title">{{ site_name|safe }}</div>
                        <div class="logo-slogan">{{ baseline|safe }}</div>
                    </a>
                    <div id="menubar">
                        <div id="mainmenu">
                            <ul class="sf-menu">
                                {% block menu_items %}
                                    {% include "navigation/menu_items.part.html" %}
                                {% endblock %}
                            </ul>
                        </div>
                    </div>
                </div>

                {% block searchform %}
                    <div id="searchform">
                        {% include "searchfield.part.html" %}
                    </div>
                {% endblock %}
                
                <div id="breadcrumb">
                    {% block breadcrumb %}
                        {% include "navigation/breadcrumb.part.html" %}
                    {% endblock %}
                </div>
            
            </div><!-- End header --> 

            <div id="wrap">
                {% block globalbar %}
                <div id="globalbar" class="sidebar">
                    <ul class="tn-box-container">
                        {% for box in global_boxes %}
                            {% include box %}
                        {% endfor %}
                    </ul>
                </div>
                {% endblock %}
                
                <div id="container">
                    {% block contextbar %}
                    <div id="contextbar" class="sidebar">
                      <ul class="tn-box-container">
                          {% for box in context_boxes %}
                              {% include box %}
                          {% endfor %}
                       </ul>
                    </div>
                    {% endblock %}
                    
                
                    <div id="content">

                        {% if messages %}
                        <div id="tn-message">
                          <ul class="messages">
                              {% for message in messages %}
                              <li{% if message.tags %} class="{{ message.tags }}"{% endif %}>{{ message|wiki }}</li>
                              {% endfor %}
                          </ul>
                        </div>
                        {% endif %}
                        
                        <h1>
                            {% block title %}
                                {{ title|safe }}
                            {% endblock %}
                        </h1>
                        
                        {% include "actions/main.part.html" %}                        
                        {% block content %}
                        {% endblock %}
                    </div>
                    <div class="clearfix"><!-- --></div>                    
                </div><!-- end #container -->  
                <div class="clearfix"><!-- --></div>
            </div><!-- end #wrap -->

            <div id="bottom">
                <div id="footer">{% blocktrans %}Powered by <a href="http://www.twistranet.com">twistranet</a> from <a href="http://www.numericube.com">numeriCube</a>{% endblocktrans %}</div>
            </div>

        </div><!-- end #wrapper -->
    </div><!-- end #page -->
    <!-- translated things used by javascript -->
    <!-- Confirmation Box -->
    <div id="tn-dialog" title="{% trans 'Confirmation Required' %}">
      <p id="tn-dialog-blockmessage">
        <span class="ui-icon ui-icon-alert"></span>
        <span id="tn-dialog-message">{% blocktrans %}Are you sure about this?{% endblocktrans %}</span>
      </p>            
        <span id="tn-dialog-button-cancel">{% blocktrans %}Cancel{% endblocktrans %}</span>
        <span id="tn-dialog-button-ok">{% blocktrans %}OK{% endblocktrans %}</span>
    </div>
    <!-- form protect against unload message -->
    <div id="form-protect-unload-message">{% blocktrans %}Changes have been made on this form, do you really want to quit without saving ?{% endblocktrans %}</div>
    <!-- write a comment message -->
    <div id="commentmessage">{% blocktrans %}Write a comment...{% endblocktrans %}</div>
</body>
</html>
