Kawai Wiki

Rev

Rev 69 | Rev 72 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
12 soliveira 1
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2
<%@taglib prefix="mtw" uri="http://www.mentaframework.org/tags-mtw/"%>
26 soliveira 3
<%@ taglib uri="/WEB-INF/tld/taglib.tld" prefix="k" %>
12 soliveira 4
 
5
<html>
6
<head>
7
 
8
<title>Mentawai Web Framework</title>
9
 
10
<style type="text/css" media="all">
31 soliveira 11
@import url("<mtw:contextPath/>/GenerateCSS.getCSS.css");
12 soliveira 12
</style>
13
 
14
<meta http-equiv="imagetoolbar" content="no" />
15
<meta http-equiv="imagetoolbar" content="false" />
16
 
17
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />
18
<link rel="icon" type="image/gif" href="/favicon.gif" />
31 soliveira 19
<link rel="stylesheet" href="<mtw:contextPath/>/GenerateCSS.getPrintCSS.css" type="text/css" media="print" />
12 soliveira 20
 
21
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
22
<meta name="author" content="Sergio Oliveira Junior" />
23
<meta name="email" content="sergio.oliveira.jr@gmail.com" />
24
 
25
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css" />
26
<script type="text/javascript" src="jquery/jquery-1.6.4.min.js"></script>
27
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
28
 
29
<script language="JavaScript">
30
 
31
        $(document).ready(function() {
33 soliveira 32
 
33
        	<mtw:if test="showForm" value="login">
39 soliveira 34
				showLoginDialog();
35
			</mtw:if>
36
 
37
			<mtw:if test="showForm" value="add">
38
				showCreateNewPageDialog();
33 soliveira 39
			</mtw:if>
35 soliveira 40
 
41
			$('#loginDialog').keyup(function(e) {
42
    			if (e.keyCode == 13) {
43
        			$('#loginForm').submit();
44
    			}
45
			});
46
 
33 soliveira 47
 
12 soliveira 48
        });
49
 
28 soliveira 50
        function prepareEditPageDialog(myDialog, theTitle) {
12 soliveira 51
 
52
            options = {
53
                autoOpen: false,
54
                width: 800,
55
                modal: true,
56
                title: theTitle,
57
                buttons: [
58
                          {
59
                                text: "Save",
28 soliveira 60
                                click: function() { $('#editPageForm').submit(); }
12 soliveira 61
                          },
62
                          {
65 soliveira 63
                                text: "Preview",
64
                                click: function() { $('#editPagePreview').val('true'); $('#editPageForm').submit(); }
65
                          },
66
                          {
12 soliveira 67
                                text: "Cancel",
68
                                click: function() { $(this).dialog("close"); }
69
                          }
70
                      ]
71
           };
72
 
73
          myDialog.dialog(options);
74
 
75
          return myDialog;
76
        }
49 soliveira 77
 
78
        function prepareListAllPagesDialog(myDialog) {
79
 
80
            options = {
81
                autoOpen: false,
82
                width: 800,
53 soliveira 83
                height: 450,
49 soliveira 84
                modal: true,
85
                title: 'Pages:',
86
                buttons: [
87
                          {
55 soliveira 88
                                text: "FrontPage",
56 soliveira 89
                                click: function() { $('#listAllPagesForm').attr('action', '<mtw:contextPath/>/Page.setFrontPage.mtw'); $('#listAllPagesForm').submit(); }
49 soliveira 90
                          },
91
                          {
55 soliveira 92
                                text: "Delete",
57 soliveira 93
                                click: function() { $('#listAllPagesForm').attr('action', '<mtw:contextPath/>/Page.delete.mtw'); $('#listAllPagesForm').submit(); }
55 soliveira 94
                          },
95
                          {
49 soliveira 96
                                text: "Close",
97
                                click: function() { $(this).dialog("close"); }
98
                          }
99
                      ]
100
           };
101
 
102
          myDialog.dialog(options);
103
 
104
          return myDialog;
105
        }
106
 
33 soliveira 107
 
41 soliveira 108
        function showEditPageDialog(pageName, lang) {
12 soliveira 109
 
41 soliveira 110
            $.getJSON('<mtw:contextPath />/Page.get.mtw?name=' + pageName + '&lang=' + lang, function(data) {
18 soliveira 111
 
28 soliveira 112
                $('#editPageTextArea').val(data.page.body);
113
                $('#editPageName').val(data.page.name);
41 soliveira 114
                $('#editPageLang').val(data.page.lang);
12 soliveira 115
 
28 soliveira 116
                myDialog = $('#editPageDialog');
117
                myDialog = prepareEditPageDialog(myDialog, 'Editing <i><font color="darkblue">' + pageName + "</font></i> in <i>" + data.page.language + "<i>...");
12 soliveira 118
                myDialog.dialog('open');
119
            });
120
 
121
            return false;
122
        }
63 soliveira 123
 
65 soliveira 124
        function showEditPreviewDialog(pageName, lang) {
49 soliveira 125
 
63 soliveira 126
            $.getJSON('<mtw:contextPath />/Page.getPreview.mtw?name=' + pageName + '&lang=' + lang, function(data) {
65 soliveira 127
 
128
                $('#editPageTextArea').val(data.page.body);
129
                $('#editPageName').val(data.page.name);
130
                $('#editPageLang').val(data.page.lang);
131
 
132
                myDialog = $('#editPageDialog');
133
                myDialog = prepareEditPageDialog(myDialog, 'Editing <i><font color="darkblue">' + pageName + "</font></i> in <i>" + data.page.language + "<i>...");
134
                myDialog.dialog('open');
135
            });
63 soliveira 136
 
65 soliveira 137
            return false;
138
        }
139
 
140
 
141
       	function showEditPreviewNewPageDialog(pageName, lang) {
142
 
143
            $.getJSON('<mtw:contextPath />/Page.getPreview.mtw?name=' + pageName + '&lang=' + lang, function(data) {
144
 
63 soliveira 145
           		$('#createNewPageName').val(data.page.name);
146
        		$('#createNewPageTitle').val(data.page.title);
147
        		$('#createNewPageLanguage').val(data.page.languageId);
148
        		$('#createNewPageTextArea').val(data.page.body);
149
        		$('#createNewPageNameError').text('');
150
        		$('#createNewPageTitleError').text('');
151
        		$('#createNewPageLanguageError').text('');
152
        		$('#createNewPageBodyError').text('');
67 soliveira 153
        		$('#createPageLanguageCell').hide();
63 soliveira 154
 
155
				showCreateNewPageDialog();
156
            });
157
 
158
            return false;
159
        }
160
 
49 soliveira 161
        function showListAllPagesDialog() {
162
 
163
            $.getJSON('<mtw:contextPath />/Page.list.mtw', function(data) {
164
 
165
                tableData = '';
166
                tableData += '<tr>';
55 soliveira 167
                tableData += '<th>&nbsp;</th>';
49 soliveira 168
                tableData += '<th>Name</th>';
169
                tableData += '<th>Language</th>';
170
                tableData += '<th>Created By</th>';
171
                tableData += '<th>Modified By</th>';
172
                tableData += '<th>&nbsp;</th>';
173
                tableData += '</tr>';
174
 
175
                $.each(data.pages, function(i,page) {
55 soliveira 176
 
177
                	pageName = page.name;
49 soliveira 178
 
179
                    modifiedBy = '';
180
                    if (page.modifiedById > 0) {
181
                        modifiedBy = page.modifiedBy.username;
182
                    }
183
 
184
                    if (page.systemPage == true) {
55 soliveira 185
                        pageName = '*' + pageName;
49 soliveira 186
                    }
187
 
188
                    if (page.frontPage == true) {
55 soliveira 189
                        pageName = '[' + pageName + ']';
49 soliveira 190
                    }
52 soliveira 191
 
192
                    modifiedOnTitle = '';
193
                    if (page.formattedModifiedOn != null) {
194
                    	modifiedOnTitle = ' title="' + page.formattedModifiedOn + '"';
195
                    }
196
 
197
                    createdOnTitle = '';
198
                    if (page.formattedCreatedOn != null) {
199
                    	createdOnTitle = ' title="' + page.formattedCreatedOn + '"';
200
                    }
53 soliveira 201
 
55 soliveira 202
                    radioCell = '&nbsp;';
53 soliveira 203
                    viewCell = '&nbsp;';
55 soliveira 204
                    if (page.CSS == false && page.systemPage == false) {
58 soliveira 205
                    	viewCell = '<a tabindex="-1" href="<mtw:contextPath/>/Page.mtw?name=' + page.name + '&lang=' + page.lang + '"><img src="<mtw:contextPath/>/images/view.png" /></a>';
55 soliveira 206
                    	if (page.frontPage == false) {
58 soliveira 207
                    		radioCell = '<input tabindex="-1" type="radio" name="pageId" id="pageId" value="' + page.id + '" />';
55 soliveira 208
                    	}
53 soliveira 209
                    }
54 soliveira 210
 
211
                    nameTitle = '';
212
                    if (page.title != null && page.title != '') {
213
                    	nameTitle = ' title="' + page.title + '"';
214
                    }
49 soliveira 215
 
216
                    tableData += '<tr>';
55 soliveira 217
                    tableData += '<td>' + radioCell + '</td>';
218
                    tableData += '<td' + nameTitle + '>' + pageName + '</td>';
49 soliveira 219
                    tableData += '<td align="center">' + page.language + '</td>';
52 soliveira 220
                    tableData += '<td align="center"' + createdOnTitle + '>' + page.createdBy.username + '</td>';
221
                    tableData += '<td align="center"' + modifiedOnTitle + '>' + modifiedBy + '</td>';
53 soliveira 222
                    tableData += '<td align="center">' + viewCell + '</td>';
49 soliveira 223
                    tableData += '</tr>';
224
                });
225
 
226
                $('#listAllPagesTable').html(tableData);
227
 
228
                myDialog = $('#listAllPagesDialog');
229
                myDialog = prepareListAllPagesDialog(myDialog);
230
                myDialog.dialog('open');
58 soliveira 231
                $('.ui-dialog :button').blur();
49 soliveira 232
             });
233
 
234
            return false;
235
        }
33 soliveira 236
 
36 soliveira 237
       	function showCreateNewPageDialog() {
238
 
42 soliveira 239
            $('#createNewPageFormName').val('<mtw:out value="bodyColumn.name" />');
240
            $('#createNewPageFormLang').val('<mtw:out value="bodyColumn.lang" />');
241
 
36 soliveira 242
            myDialog = $('#createNewPageDialog');
243
            myDialog = prepareCreateNewPageDialog(myDialog);
244
            myDialog.dialog('open');
245
 
246
            return false;
247
        }
248
 
249
        function prepareCreateNewPageDialog(myDialog) {
250
 
251
            options = {
38 soliveira 252
            	close: function() { clearCreateNewPageForm(); },
36 soliveira 253
                autoOpen: false,
254
                width: 800,
255
                modal: true,
256
                title: "Create New Page:",
257
                buttons: [
258
                          {
38 soliveira 259
                                text: "Create",
260
                                click: function() { $('#createNewPageForm').submit(); }
36 soliveira 261
                          },
262
                          {
60 soliveira 263
                              text: "Preview",
264
                              click: function() { $('#createNewPageFormPreview').val('true'); $('#createNewPageForm').submit(); }
265
                          },
266
                          {
36 soliveira 267
                                text: "Cancel",
37 soliveira 268
                                click: function() {  $(this).dialog("close"); }
36 soliveira 269
                          }
270
                      ]
271
           };
272
 
273
          myDialog.dialog(options);
274
 
275
          return myDialog;
276
        }
277
 
33 soliveira 278
 
279
        function showLoginDialog() {
12 soliveira 280
 
42 soliveira 281
            $('#loginFormName').val('<mtw:out value="bodyColumn.name" />');
282
            $('#loginFormLang').val('<mtw:out value="bodyColumn.lang" />');
283
 
33 soliveira 284
            myDialog = $('#loginDialog');
285
            myDialog = prepareLoginDialog(myDialog);
286
            myDialog.dialog('open');
287
 
288
            return false;
289
        }
290
 
35 soliveira 291
        function clearLoginForm() {
292
        	$('#loginUsername').val('');
293
        	$('#loginPassword').val('');
294
        	$('#loginUsernameError').text('');
295
        	$('#loginPasswordError').text('');
36 soliveira 296
        }
33 soliveira 297
 
36 soliveira 298
        function clearCreateNewPageForm() {
299
        	$('#createNewPageName').val('');
300
        	$('#createNewPageTitle').val('');
301
        	$('#createNewPageLanguage').val('');
302
        	$('#createNewPageTextArea').val('');
39 soliveira 303
        	$('#createNewPageNameError').text('');
304
        	$('#createNewPageTitleError').text('');
305
        	$('#createNewPageLanguageError').text('');
306
        	$('#createNewPageBodyError').text('');
36 soliveira 307
        }
308
 
33 soliveira 309
      	function prepareLoginDialog(myDialog) {
310
 
311
            options = {
35 soliveira 312
            	close: function() { clearLoginForm(); },
33 soliveira 313
                autoOpen: false,
314
                width: 290,
315
                modal: true,
316
                title: "Login:",
317
                buttons: [
318
                          {
319
                                text: "Login",
320
                                click: function() { $('#loginForm').submit(); }
321
                          },
322
                          {
323
                                text: "Cancel",
37 soliveira 324
                                click: function() {  $(this).dialog("close"); }
33 soliveira 325
                          }
326
                      ]
327
           };
328
 
329
          myDialog.dialog(options);
330
 
331
          return myDialog;
332
        }
37 soliveira 333
 
334
      	function prepareConfirmDialog(myDialog) {
33 soliveira 335
 
37 soliveira 336
            options = {
337
                autoOpen: false,
338
                width: 300,
339
                modal: true,
340
                title: "Confirmation:",
341
                buttons: [
342
                          {
343
                                text: "Yes",
344
                                click: function() { $(this).dialog("close"); }
345
                          },
346
                          {
347
                                text: "No",
348
                                click: function() {  $(this).dialog("close"); }
349
                          }
350
                      ]
351
           };
352
 
353
          myDialog.dialog(options);
354
 
355
          return myDialog;
356
        }
357
 
358
         function showConfirmDialog() {
359
 
360
            myDialog = $('#confirmDialog');
361
            myDialog = prepareConfirmDialog(myDialog);
362
            myDialog.dialog('open');
363
 
364
            return false;
365
        }
366
 
12 soliveira 367
    </script>
368
 
369
</head>
370
 
371
<body class="composite">
372
 
373
<!-- For Testing -->
374
<div id="dialog" title="Dialog Title" style="display: none;">I'm in a dialog</div>
375
 
37 soliveira 376
<!-- Close Confirm -->
377
<div id="confirmDialog" style="display: none;">
378
	<span id="confirmMessage">The confirmation message goes here.</span>
379
</div>
380
 
33 soliveira 381
<!-- For Editing Pages -->
28 soliveira 382
<div id="editPageDialog" style="display: none;">
41 soliveira 383
<form id="editPageForm" action="<mtw:contextPath />/Page.edit.mtw" method="post">
28 soliveira 384
<input type="hidden" name="name" id ="editPageName" value="" />
41 soliveira 385
<input type="hidden" name="lang" id="editPageLang" value="" />
65 soliveira 386
<input type="hidden" name="isPreview" id="editPagePreview" value="false" />
12 soliveira 387
<table>
388
    <tr>
389
        <td>&nbsp;</td>
390
    </tr>
28 soliveira 391
    <mtw:outError field="html">
12 soliveira 392
        <tr>
393
            <td colspan="2"><span class="Negative" style="font-weight: bold;"><mtw:out /></span></td>
394
        </tr>
395
    </mtw:outError>
396
    <tr>
28 soliveira 397
        <td colspan="2"><mtw:textarea id="editPageTextArea" name="body" style="width: 100%; height: 465px;" /></td>
12 soliveira 398
    </tr>
399
</table>
400
</form>
401
</div>
402
 
33 soliveira 403
<!-- For Login -->
404
<div id="loginDialog" style="display: none;">
405
		<form action="<mtw:contextPath />/Login.mtw" method="post" id="loginForm">
42 soliveira 406
            <input type="hidden" name="name" value="" id="loginFormName" />
407
            <input type="hidden" name="lang" value="" id="loginFormLang" />
33 soliveira 408
			<table>
409
				<tr>
410
					<td>
411
						Username:
412
					</td>
413
					<td>
35 soliveira 414
						<mtw:input id="loginUsername" name="username" size="20" maxlength="20" />
415
						<span id="loginUsernameError">
33 soliveira 416
						<mtw:outError field="username">
417
							<font color="red">
418
								<b><mtw:out /></b>
419
							</font>
420
						</mtw:outError>
35 soliveira 421
						</span>
33 soliveira 422
					</td>
423
				</tr>
424
				<tr>
425
					<td>
426
						Password:
427
					</td>
428
					<td>
35 soliveira 429
						<mtw:input id="loginPassword" name="password" type="password" size="20" maxlength="20" />
430
						<span id="loginPasswordError">
33 soliveira 431
						<mtw:outError field="password">
432
							<font color="red">
433
								<b><mtw:out /></b>
434
							</font>
435
						</mtw:outError>
35 soliveira 436
						</span>
33 soliveira 437
					</td>
438
				</tr>
439
			</table>
440
		</form>
441
</div>
442
 
49 soliveira 443
<!-- For displaying all pages -->
444
<div id="listAllPagesDialog" style="display: none;">
56 soliveira 445
    <form action="#" method="post" id="listAllPagesForm">
53 soliveira 446
    <table id="listAllPagesTable">
49 soliveira 447
    </table>
56 soliveira 448
    </form>
49 soliveira 449
</div>
450
 
36 soliveira 451
<!-- Create New Page -->
452
<div id="createNewPageDialog" style="display: none;">
453
		<form action="<mtw:contextPath />/Page.add.mtw" method="post" id="createNewPageForm">
42 soliveira 454
            <input type="hidden" name="name" value="" id="createNewPageFormName" />
455
            <input type="hidden" name="lang" value="" id="createNewPageFormLang" />
60 soliveira 456
            <input type="hidden" name="isPreview" value="false" id="createNewPageFormPreview" />
36 soliveira 457
			<table>
458
				<tr>
459
					<td>
460
						Name:
461
					</td>
462
					<td>
39 soliveira 463
						<mtw:input id="createNewPageName" name="newPage.name" size="40" maxlength="30" />
36 soliveira 464
						<span id="createNewPageNameError">
39 soliveira 465
						<mtw:outError field="newPage.name">
36 soliveira 466
							<font color="red">
467
								<b><mtw:out /></b>
468
							</font>
469
						</mtw:outError>
470
						</span>
471
					</td>
472
				</tr>
473
				<tr>
474
					<td>
475
						Title:
476
					</td>
477
					<td>
39 soliveira 478
						<mtw:input id="createNewPageTitle" name="newPage.title" size="40" maxlength="60" />
36 soliveira 479
						<span id="createNewPageTitleError">
39 soliveira 480
						<mtw:outError field="newPage.title">
36 soliveira 481
							<font color="red">
482
								<b><mtw:out /></b>
483
							</font>
484
						</mtw:outError>
485
						</span>
486
					</td>
487
				</tr>
67 soliveira 488
				<tr id="createPageLanguageCell">
36 soliveira 489
					<td>
490
						Language:
491
					</td>
492
					<td>
39 soliveira 493
						<mtw:select name="newPage.languageId" list="languages" id="createNewPageLanguage" emptyField="true" />
36 soliveira 494
						<span id="createNewPageLanguageError">
39 soliveira 495
						<mtw:outError field="newPage.languageId">
36 soliveira 496
							<font color="red">
497
								<b><mtw:out /></b>
498
							</font>
499
						</mtw:outError>
500
						</span>
501
					</td>
502
				</tr>
503
				<tr>
39 soliveira 504
        			<td colspan="2">
505
        				<mtw:textarea id="createNewPageTextArea" name="newPage.body" style="width: 100%; height: 465px;" />
506
        				<span id="createNewPageBodyError">
507
						<mtw:outError field="newPage.body">
508
							<font color="red">
509
								<b><mtw:out /></b>
510
							</font>
511
						</mtw:outError>
512
						</span>
513
        			</td>
36 soliveira 514
    			</tr>
515
			</table>
516
		</form>
517
</div>
33 soliveira 518
 
36 soliveira 519
 
12 soliveira 520
<div>
521
<table border="0">
522
    <tr>
39 soliveira 523
        <td><a href="<mtw:contextPath/>"><img src="images/logos/logo.png" border="0"></img></a></td>
22 soliveira 524
        <td align="right" valign="bottom">
525
            <mtw:isLogged negate="true">
33 soliveira 526
                <a href="#" onclick="return showLoginDialog();">Login</a>
22 soliveira 527
            </mtw:isLogged>
528
            <mtw:isLogged>
36 soliveira 529
                <a href="#" onclick="return showCreateNewPageDialog();">Create New Page</a> |
49 soliveira 530
                <a href="#" onclick="return showListAllPagesDialog();">List Pages</a> |
44 soliveira 531
                <mtw:hasAuthorization groups="admin">
41 soliveira 532
                <a href="#" onclick="return showEditPageDialog('CSS', 'en');" title="<k:editTooltip name="css" />">Edit CSS</a> |
44 soliveira 533
                </mtw:hasAuthorization>
22 soliveira 534
                <a href="<mtw:contextPath/>/Logout.mtw">Logout</a> (<mtw:out value="sessionUser.username" />)
535
            </mtw:isLogged>
536
            &nbsp;
39 soliveira 537
            <mtw:isLocale value="pt">
538
	            <a href="<mtw:urlWithLoc loc="pt" />"><img src="images/brazil.gif" border="0" width="20" height="13" style="border: 3px solid #ccc;" /></a>
539
    	        <a href="<mtw:urlWithLoc loc="en" />"><img src="images/usa.gif" width="20" height="13" border="0" style="border: 3px solid #fff;" /></a>
540
            </mtw:isLocale>
541
            <mtw:isLocale value="en">
542
            	<a href="<mtw:urlWithLoc loc="pt" />"><img src="images/brazil.gif" border="0" width="20" height="13" style="border: 3px solid #fff;" /></a>
543
            	<a href="<mtw:urlWithLoc loc="en" />"><img src="images/usa.gif" width="20" height="13" border="0" style="border: 3px solid #ccc;" /></a>
544
            </mtw:isLocale>
22 soliveira 545
            &nbsp;&nbsp;&nbsp;
546
        </td>
12 soliveira 547
    </tr>
548
</table>
549
</div>
550
 
551
<hr />
552
 
553
<div id="leftColumn"><mtw:isLogged>
44 soliveira 554
    <mtw:hasAuthorization groups="admin">
41 soliveira 555
        <div style="text-align: right; padding-right: 14px; padding-top: 6px;"><a href="#" onclick="return showEditPageDialog('LeftColumn', '<mtw:out value="leftColumn.language.locale" />');" title="<k:editTooltip name="leftColumn" />">Edit</a></div>
12 soliveira 556
    </mtw:hasAuthorization>
557
</mtw:isLogged>
20 soliveira 558
<div id="navcolumn">
559
    <div>
22 soliveira 560
    <mtw:out value="leftColumn.body" />
20 soliveira 561
    </div>
562
<br />
12 soliveira 563
</div>
564
 
565
</div>
566
 
567
<div id="bodyColumn">
28 soliveira 568
    <mtw:hasAuthorization groups="admin, editor">
63 soliveira 569
 
570
    <mtw:if test="bodyColumn.preview" value="true">
65 soliveira 571
 
572
    	<mtw:if test="bodyColumn.new" value="true">
71 soliveira 573
			<div style="text-align: left; padding-left: 4px;">
574
			<b>This is a Preview</b>
575
			&nbsp;-&nbsp;
576
            <a href="<mtw:contextPath/>/Page.savePreview.mtw?name=<mtw:out value="bodyColumn.name" />&lang=<mtw:out value="bodyColumn.language.locale" />">Save</a>&nbsp;&nbsp;
577
            <a href="#" onclick="return showEditPreviewNewPageDialog('<mtw:out value="bodyColumn.name" />', '<mtw:out value="bodyColumn.language.locale" />');" title="<k:editTooltip name="bodyColumn" />">Edit</a>&nbsp;&nbsp;
69 soliveira 578
			<a href="<mtw:contextPath/>/Page.discardPreview.mtw?name=<mtw:out value="bodyColumn.name" />&lang=<mtw:out value="bodyColumn.language.locale" />">Discard</a>
66 soliveira 579
			</div>
65 soliveira 580
    	</mtw:if>
581
    	<mtw:if test="bodyColumn.new" value="false">
71 soliveira 582
            <div style="text-align: left; padding-left: 4px;">
583
            <b>This is a Preview</b>
584
            &nbsp;-&nbsp;
585
            <a href="<mtw:contextPath/>/Page.savePreview.mtw?name=<mtw:out value="bodyColumn.name" />&lang=<mtw:out value="bodyColumn.language.locale" />">Save</a>&nbsp;&nbsp;
586
            <a href="#" onclick="return showEditPreviewDialog('<mtw:out value="bodyColumn.name" />', '<mtw:out value="bodyColumn.language.locale" />');" title="<k:editTooltip name="bodyColumn" />">Edit</a>&nbsp;&nbsp;
587
            <a href="<mtw:contextPath/>/Page.discardPreview.mtw?name=<mtw:out value="bodyColumn.name" />&lang=<mtw:out value="bodyColumn.language.locale" />">Discard</a>
66 soliveira 588
			</div>
65 soliveira 589
    	</mtw:if>
590
 
63 soliveira 591
    </mtw:if>
592
 
593
    <mtw:if test="bodyColumn.preview" value="false">
41 soliveira 594
    <div style="text-align: right; padding-right: 14px;"><a href="#" onclick="return showEditPageDialog('<mtw:out value="bodyColumn.name" />', '<mtw:out value="bodyColumn.language.locale" />');" title="<k:editTooltip name="bodyColumn" />">Edit</a></div>
63 soliveira 595
    </mtw:if>
596
 
28 soliveira 597
    </mtw:hasAuthorization>
24 soliveira 598
    <mtw:out value="bodyColumn.body" />
12 soliveira 599
</div>
600
 
601
<div class="clear">
602
<hr />
603
</div>
604
 
605
<div id="footer">
63 soliveira 606
<div class="xright">Copyright (c) 2011</div>
12 soliveira 607
<div class="clear">
608
<hr />
609
</div>
610
</div>
611
 
612
</body>
613
</html>