View File | Revision Log | Show Annotations | Download File | View Changeset
/hippo/hippo-cms6/hippo-cms/branches/Branch-CMS-v6_05_xx/editor/src/site/workbench/transformers/top.xsl
Revision: 10202
Committed: Thu Jan 31 15:25:51 2008 UTC (12 years, 5 months ago) by mvos
Content type: application/xml
Original Path: hippo-cms/branches/Branch-CMS-v6_05_xx/editor/src/site/workbench/transformers/top.xsl
File size: 12372 byte(s)
Log Message:
CMSSIX-99: enable custom replacements of any possible error message.

File Contents

# Content
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!--
3 Copyright 2001-2007 Hippo (www.hippo.nl)
4
5 Licensed under the Apache License, Version 2.0 (the "License");
6 you may not use this file except in compliance with the License.
7 You may obtain a copy of the License at
8
9 http://www.apache.org/licenses/LICENSE-2.0
10
11 Unless required by applicable law or agreed to in writing, software
12 distributed under the License is distributed on an "AS IS" BASIS,
13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 See the License for the specific language governing permissions and
15 limitations under the License.
16 -->
17 <!--
18 Top frame
19 Loads the CMS framework javascript classes and startup script
20 Draws tab headers
21 -->
22
23 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
24 xmlns:i18n="http://apache.org/cocoon/i18n/2.1">
25
26 <xsl:param name="username"/>
27 <xsl:param name="fullname"/>
28 <xsl:param name="editUri"/>
29 <xsl:param name="editType"/>
30 <xsl:param name="previewURL"/>
31 <xsl:param name="randomNr"/>
32
33 <xsl:template match="/">
34 <html>
35
36 <head>
37 <title>Hippo CMS Tab Menu</title>
38 <link href="/workbench/css/top_layout_browser_generic.css" rel="stylesheet" type="text/css" media="all" />
39 <link href="/workbench/css/top_style_browser_generic.css" rel="stylesheet" type="text/css" media="all" />
40 <link href="/workbench/css/topstyle.css" rel="stylesheet" type="text/css" media="all" />
41
42 <!-- Class framework's -->
43 <scriptpackage id="external" inline="true">
44 <script type="text/javascript" src="/workbench/js/cfx/Cfx.js">&#160;</script>
45 <script type="text/javascript" src="/js/scriptaculous/lib/prototype.js">&#160;</script>
46 </scriptpackage>
47
48 <scriptpackage id="hippoFramework">
49
50 <!-- Load helper functions and classes -->
51 <script type="text/javascript" src="/workbench/js/hippo/util.js">&#160;</script>
52
53 <!-- Framework classes -->
54 <script type="text/javascript" src="/workbench/js/hippo/framework/logger.js">&#160;</script>
55 <script type="text/javascript" src="/workbench/js/hippo/framework/loggertranslations.js">&#160;</script>
56 <script type="text/javascript" src="/workbench/js/hippo/framework/start.js">&#160;</script>
57 <script type="text/javascript" src="/workbench/js/hippo/framework/context.js">&#160;</script>
58 <script type="text/javascript" src="/workbench/js/hippo/framework/services.js">&#160;</script>
59 <script type="text/javascript" src="/workbench/js/hippo/framework/components.js">&#160;</script>
60 <script type="text/javascript" src="/workbench/js/hippo/framework/events.js">&#160;</script>
61 <script type="text/javascript" src="/workbench/js/hippo/framework/event_util.js">&#160;</script>
62 <script type="text/javascript" src="/workbench/js/hippo/framework/remotecall.js">&#160;</script>
63 <script type="text/javascript" src="/workbench/js/hippo/framework/remotecall-ajax.js">&#160;</script>
64 <script type="text/javascript" src="/workbench/js/hippo/framework/authentication.js">&#160;</script>
65
66 <!-- non-standard framework source files from xml-configuration -->
67 <xsl:apply-templates select="/root/sources[@context='Framework']/*"/>
68 </scriptpackage>
69
70 <!-- Load framework configuration -->
71 <script type="text/javascript" src="/workbench/js/FrameworkConfiguration.js?{$randomNr}=">&#160;</script>
72
73 <!-- Application classes -->
74 <scriptpackage id="hippoApplication">
75 <script type="text/javascript" src="/workbench/js/hippo/cms.js">&#160;</script>
76 <script type="text/javascript" src="/workbench/js/hippo/workbench.js">&#160;</script>
77 <script type="text/javascript" src="/workbench/js/hippo/container.js">&#160;</script>
78 <script type="text/javascript" src="/workbench/js/hippo/perspectives.js">&#160;</script>
79 <script type="text/javascript" src="/workbench/js/hippo/views.js">&#160;</script>
80 <script type="text/javascript" src="/workbench/js/hippo/keyboard.js">&#160;</script>
81
82 <!-- non-standard application source files from xml-configuration -->
83 <xsl:apply-templates select="/root/sources[@context='Application']/*"/>
84 </scriptpackage>
85
86 <!-- Load application configuration -->
87 <script type="text/javascript" src="/workbench/js/ApplicationConfiguration.js?{$randomNr}=">&#160;</script>
88
89 <script>
90 var documentIsOpen = "false";
91 function openDocument(state)
92 {
93 documentIsOpen = state;
94 }
95 var scheduledTasks = new Array();
96
97 <xsl:choose>
98 <xsl:when test="string-length($editUri) &gt; 0 and string-length($editType) &gt; 0">
99 scheduledTasks[scheduledTasks.length] = {'event':'editDocument','arguments':[{key:'url',val:'<xsl:value-of select="$editUri"/>'},{key:'type',val:'<xsl:value-of select="$editType"/>'}]};
100 </xsl:when>
101 <xsl:when test="string-length($editUri) &gt; 0 and string-length($editType) = 0">
102 scheduledTasks[scheduledTasks.length] = {'event':'selectSource','arguments':[{key:'url',val:'<xsl:value-of select="$editUri"/>'}]};
103 </xsl:when>
104 </xsl:choose>
105
106 //temporary workaround for 6.0.3.1 ONLY!
107 var CMS_PREVIEW_URL = '<xsl:value-of select="$previewURL"/>';
108 </script>
109
110 </head>
111
112 <!-- [DD] locking not supported now -->
113 <!--body onbeforeunload="window.location.href='/login/removeLocks';"-->
114 <body>
115 <!-- start body-->
116 <div id="container_main">
117 <!-- start top-->
118 <div id="top">
119 <!-- start top left: logo & navigation-->
120 <div id="top_left_container" >
121 <xsl:if test="count(/root/application//perspectives/perspective) &gt; 5">
122 <!-- default width in css is to small to align all icons when > 5 -->
123 <xsl:attribute name="style">width:<xsl:value-of select="count(/root/application//perspectives/perspective) * 116"/>px;</xsl:attribute>
124 </xsl:if>
125 <div id="logo">
126 <img class="unselectable" unselectable="on" src="/skins/images/logo_top.gif" alt="Hippo CMS" width="170" height="27"/>
127 </div>
128 <!-- start top navigation-->
129 <div id="nav">
130 <xsl:apply-templates select="/root/application//perspectives/*"/>
131 </div>
132 <!-- end top navigation-->
133 </div>
134 <!-- end top left-->
135 <!-- start top right: user data & search field-->
136 <div id="top_right_container_top">
137 <table cellspacing="0" cellpadding="3" class="user_data" border="0">
138 <tr>
139 <td class="unselectable username" unselectable="on">
140 <!--div id="usernameBox"-->
141 <xsl:choose>
142 <xsl:when test="string-length($fullname)&gt;0">
143 <xsl:value-of select="$fullname"/>
144 </xsl:when>
145 <xsl:otherwise>
146 <xsl:value-of select="$username"/>
147 </xsl:otherwise>
148 </xsl:choose>
149 <!--/div-->
150 </td>
151 <td class="unselectable" unselectable="on">
152 <img src="/skins/images/user_top.gif" alt="" width="10" height="8"/>
153 </td>
154 <td class="unselectable" unselectable="on">
155 <a href="/login/logout" target="_top">
156 <i18n:text>topmenu.logoffmessage</i18n:text>
157 </a>
158 </td>
159 <td class="unselectable" unselectable="on">
160 <a href="/login/logout" target="_top" class="unselectable" unselectable="on"
161 onfocus="document.getElementById('logoffIcon').style.border='1px solid #666';"
162 onblur="document.getElementById('logoffIcon').style.border='0px';">
163 <img src="/skins/images/logout.gif" alt="log out" width="14" height="9"/>
164 </a>
165 </td>
166 </tr>
167 </table>
168 <form style="padding:0px; margin:0px;">
169 <xsl:attribute name="onsubmit">
170 <xsl:text>fireCMSEvent('doSearch',[{key:'reportID',val:'adv'},{key:'simpleSearch',val:document.getElementById('topSimpleSearch').value}]); return false;</xsl:text>
171 </xsl:attribute>
172 <table cellspacing="0" cellpadding="0" class="search_top" border="0">
173 <tr>
174 <td id="waitImage" style="visibility:hidden; vertical-align: bottom;">
175 <img class="unselectable" unselectable="on" src="/skin/images/clock_05.gif" alt="" width="26" height="24"/>
176 </td>
177 <td>&#160;</td>
178 <td class="search_top_divider_L"/>
179 <td class="form">
180 <input type="text" name="topSimpleSearch" id="topSimpleSearch"/>
181 </td>
182 <td class="form">&#160;</td>
183 <td class="form">
184 <button type="button" name="search" value="search" id="topSearchBtn">
185 <xsl:attribute name="onclick">
186 <xsl:text>fireCMSEvent('doSearch',[{key:'reportID',val:'adv'},{key:'simpleSearch',val:document.getElementById('topSimpleSearch').value}])</xsl:text>
187 </xsl:attribute>
188 <i18n:text>topmenu.toolbar.search</i18n:text>
189 </button>
190 </td>
191 <td class="search_top_divider_R"/>
192 </tr>
193 </table>
194 </form>
195 </div>
196 <!-- <div id="top_right_container_bottom">
197
198 </div>-->
199 <!-- end top right -->
200 </div>
201 <!-- end top -->
202 <!-- start horizontal gray divider & breadcrumb bar-->
203 <div id="top_divider">&#160;</div>
204 <div unselectable="on" id="top_path_bar" class="unselectable">
205 <i18n:text>topmenu.toolbar.home</i18n:text>
206 <span id="top_breadcrumb" unselectable="on" class="unselectable">&#160;</span>
207 <span id="search_result_summary" unselectable="on" class="unselectable"></span>
208 <span id="search_result_extended_summary" unselectable="on" class="unselectable"></span>
209 </div>
210 <!-- end horizontal gray divider -->
211 </div>
212 </body>
213
214 </html>
215
216 </xsl:template>
217
218 <xsl:template match="perspective">
219 <table unselectable="on" cellspacing="0" cellpadding="0" class="nav_tbl unselectable">
220 <xsl:attribute name="onclick">fireCMSEvent('setFocus',[{key:'perspectiveID',val:'<xsl:value-of select="@id"/>'}])</xsl:attribute>
221 <xsl:attribute name="onfocus">this.blur();</xsl:attribute>
222 <xsl:attribute name="ondblclick">fireCMSEvent('reloadActivePerspective',[]);</xsl:attribute>
223 <tr>
224 <td unselectable="on" id="{@id}_tab_top" class="tab_top_empty unselectable"></td>
225 </tr>
226 <tr>
227 <td class="unselectable" id="{@id}" unselectable="on">
228 <div class="perspectiveTab unselectable" unselectable="on">
229 <xsl:attribute name="style">
230 <xsl:text>background: url(/skins/images/icons/24x24/</xsl:text>
231 <xsl:value-of select="@icon"/>
232 <xsl:text>.gif) 4px 2px no-repeat;</xsl:text>
233 </xsl:attribute>
234 <a href="#" unselectable="on" class="unselectable">
235 <xsl:value-of select="@label"/>
236 </a>
237 </div>
238 </td>
239 </tr>
240 </table>
241 </xsl:template>
242
243 <xsl:template match="perspective" mode="top-path-bar">
244 </xsl:template>
245
246 <xsl:template match="source">
247 <xsl:if test="string-length(.)&gt;0">
248 <script type="text/javascript" src="{.}">&#160;</script>
249 </xsl:if>
250 </xsl:template>
251
252 <xsl:template match="*" />
253
254 </xsl:stylesheet>

Properties

Name Value
svn:eol-style native
svn:keywords Id