Dotclear

source: inc/admin/default-templates/layout.html.twig @ 1074:57967b687622

Revision 1074:57967b687622, 4.8 KB checked in by JcDenis, 13 years ago (diff)
  • dcPage::open and dcPage::close now use template
Line 
1{% import "js_helpers.html.twig" as js %}
2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="{{current_user.lang}}" lang="{{current_user.lang}}">
4<head>
5     {% block header %}
6     <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
7     <title>{% block title %}{{page_title}} - {% if current_blog.name is not empty %}{{current_blog.name}} - {% endif %}{{vendor_name}} - {{version}}{% endblock %}</title>
8     <meta name="ROBOTS" content="NOARCHIVE,NOINDEX,NOFOLLOW" />
9     <meta name="GOOGLEBOT" content="NOSNIPPET" />
10     <link rel="stylesheet" href="{{theme_url}}style/default.css" type="text/css" media="screen" />
11     {% if rtl is not empty %}
12     <link rel="stylesheet" href="{{theme_url}}style/default-rtl.css" type="text/css" media="screen" />
13     {% endif %}
14     {{ js.load_IE7 }}
15     {{ js.common }}
16     {% endblock %}
17</head>
18
19<body id="dotclear-admin{% if safe_mode %} safe-mode{% endif %}">
20     <div id="header">
21          <ul id="prelude">
22               <li><a href="#content">{{__('To content')}}</a></li>
23               <li><a href="#main-menu">{{__('To menu')}}</a></li>
24          </ul>
25          <div id="top"><h1><a href="index.php">{{vendor_name}}</a></h1></div>
26          <div id="info-boxes">
27               <div id="info-box1">
28                 {% form switchblog_menu %}
29                    {% if blog_count > 1 and blog_count < 20 %}
30                         {{ form_field('switchblog') }}
31                         <noscript><div>{{ form_field('switchblog_submit') }}</div></noscript>
32                    {% else %}
33                         {{__('Blog:')}} <strong title="{{current_blog.url}}">{{current_blog.name}}</strong>
34                         {% if blogs is not empty %} - <a href="blogs.php">{{__('Change blog')}}</a>{% endif %}
35                    {% endif %}
36                    <a href="{{current_blog.url}}" onclick="window.open(this.href);return false;" title="{{__('Go to site')}} ({{__('new window')}})">{{__('Go to site')}} <img src="{{theme_url}}images/outgoing.png" alt="" /></a>
37                 {% endform %}
38               </div>
39               <div id="info-box2">
40                    <a {%if current_page == 'index' %}class="active" {% endif %}href="index.php">{{__('My dashboard')}}</a><span> | </span>
41                    <a {%if current_page == 'preferences' %}class="active" {% endif %}href="preferences.php">{{__('My preferences')}}</a><span> | </span>
42                    <a href="index.php?logout=1" class="logout">{{__('Logout %s')|format(current_user.id)}} <img src="images/logout.png" alt="" /></a>
43               </div>
44          </div>
45     </div>
46     <div id="wrapper">
47          <div id="main">
48               <div id="content">
49                    {% block content %}
50                    {% if safe_mode %}
51                         <div class="error"><h3>{{__('Safe mode')}}</h3>
52                         <p>{{__('You are in safe mode. All plugins have been temporarily disabled. Remind to log out then log in again normally to get back all functionalities')}}</p>
53                         </div>
54                    {% endif %}
55                    <h2>{{current_blog.name}} &rsaquo; <span class="page-title">{{page_title}}</span></h2>
56                    {% if page_message is not empty %}
57                         <p class="message">{{page_message}}</p>
58                    {% endif %}
59                    {% if page_errors is not empty %}
60                         <div class="error">
61                              <p><strong>Errors :</strong></p>
62                              <ul>
63                              {% for error in page_errors %}
64                                   <li>{{error}}</li>
65                              {% endfor %}
66                              </ul>
67                         </div>
68                    {% endif %}
69                    {% endblock %}
70
71               </div>
72          </div>
73          <div id="main-menu">
74               {% block menus %}
75               {% for menu in menus %}
76               {% if menu.items is not empty %}
77               <div id="{{menu.id}}">
78                    {% if menu.title is not empty %}<h3>{{menu.title}}</h3>{% endif %}
79                    <ul>
80                    {% for item in menu.items %}
81                    {% spaceless %}
82                    <li {% if item.active or item.class is not empty %} class="{% if item.active %}active {% endif %}{{item.class}}"{% endif %}
83                    {% if item.id is not empty %}id="{{item.id}}" {% endif %}
84                    {% if item.img is not empty %} style="background-image: url({{item.img}});"{% endif %}
85                    ><a href="{{item.link}}"{{item.ahtml}}>{{item.title}}</a>
86                    {% if loop.last %}{{menu.separator}}{% endif %}</li>
87                    {% endspaceless %}
88                    {% endfor %}
89                    </ul>
90               </div>
91               {% endif %}
92               {% endfor %}
93               {% endblock %}
94          </div>
95          <div id="footer">
96               {% block footer %}
97               <p>{{ __('Thank you for using %s.')|format(vendor_name) }}</p>
98               {% endblock %}
99          </div>
100     </div>
101     {% block debug %}
102       {% set debug_info = debug_info() %}
103       {% if debug_info is not empty %}
104          <div id="debug"><div>
105          <p>memory usage: {{ debug_info.memory.usage }} ({{ debug_info.memory.size }})</p>
106          {% if debug_info.xdebug is not empty %}
107            <p>Elapsed time: {{ debug_info.xdebug.elapse_time }} seconds</p>
108            {% if debug_info.xdebug.profiler_file is not empty %}
109               <p>Profiler file : {{ debug_info.xdebug.profiler_file }}</p>
110            {% else %}
111               <p><a href="{{ debug_info.xdebug.profiler_url }}">Trigger profiler</a></p>
112            {% endif %}
113          {% endif %}
114          <p>Global vars: {{ debug_info.global_vars }}</p>
115          </div></div>
116       {% endif %}
117     {% endblock %}
118     </body>
119</html>
Note: See TracBrowser for help on using the repository browser.

Sites map