Kawai Wiki

Rev

Rev 25 | Rev 28 | 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">
11
@import url("./style/maven-base.css");
12
 
13
@import url("./style/maven-theme.css");
14
</style>
15
 
16
<meta http-equiv="imagetoolbar" content="no" />
17
<meta http-equiv="imagetoolbar" content="false" />
18
 
19
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />
20
<link rel="icon" type="image/gif" href="/favicon.gif" />
21
<link rel="stylesheet" href="./style/print.css" type="text/css" media="print" />
22
 
23
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
24
<meta name="author" content="Sergio Oliveira Junior" />
25
<meta name="email" content="sergio.oliveira.jr@gmail.com" />
26
 
27
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css" />
28
<script type="text/javascript" src="jquery/jquery-1.6.4.min.js"></script>
29
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"></script>
30
 
31
<script language="JavaScript">
32
 
33
        $(document).ready(function() {
34
 
35
        });
36
 
37
        function prepareLeftColumnDialog(myDialog, theTitle) {
38
 
39
            options = {
40
                autoOpen: false,
41
                width: 800,
42
                modal: true,
43
                title: theTitle,
44
                buttons: [
45
                          {
46
                                text: "Save",
47
                                click: function() { $('#editLeftColumnForm').submit(); }
48
                          },
49
                          {
50
                                text: "Cancel",
51
                                click: function() { $(this).dialog("close"); }
52
                          }
53
                      ]
54
           };
55
 
56
          myDialog.dialog(options);
57
 
58
          return myDialog;
59
        }
60
 
61
        function showEditLeftColumnDialog(pageName) {
62
 
63
            $.getJSON('<mtw:contextPath />/Page.getLeftColumn.mtw', function(data) {
18 soliveira 64
 
22 soliveira 65
                $('#editLeftColumnTextArea').val(data.leftColumn.body);
12 soliveira 66
 
67
                myDialog = $('#editLeftColumnDialog');
68
                myDialog = prepareLeftColumnDialog(myDialog, "Edit Left Column");
69
                myDialog.dialog('open');
70
            });
71
 
72
            return false;
73
        }
74
 
75
    </script>
76
 
77
</head>
78
 
79
<body class="composite">
80
 
81
<!-- For Testing -->
82
<div id="dialog" title="Dialog Title" style="display: none;">I'm in a dialog</div>
83
 
84
<div id="editLeftColumnDialog" style="display: none;">
85
<form id="editLeftColumnForm" action="<mtw:contextPath />/Page.editLeftColumn.mtw" method="post">
86
<table>
87
    <tr>
88
        <td>&nbsp;</td>
89
    </tr>
90
    <mtw:outError field="answer">
91
        <tr>
92
            <td colspan="2"><span class="Negative" style="font-weight: bold;"><mtw:out /></span></td>
93
        </tr>
94
    </mtw:outError>
95
    <tr>
96
        <td colspan="2"><mtw:textarea id="editLeftColumnTextArea" name="html" style="width: 100%; height: 465px;" /></td>
97
    </tr>
98
</table>
99
</form>
100
</div>
101
 
102
<div>
103
<table border="0">
104
    <tr>
105
        <td><a href="/"><img src="images/logos/logo.png" border="0"></img></a></td>
22 soliveira 106
        <td align="right" valign="bottom">
107
            <mtw:isLogged negate="true">
108
                <a href="jsp/login.jsp">Login</a>
109
            </mtw:isLogged>
110
            <mtw:isLogged>
111
                <a href="<mtw:contextPath/>/Page.create.mtw">Create New Page</a> |
112
                <a href="<mtw:contextPath/>/Page.list.mtw">List Pages</a> |
113
                <a href="<mtw:contextPath/>/Logout.mtw">Logout</a> (<mtw:out value="sessionUser.username" />)
114
            </mtw:isLogged>
115
            &nbsp;
116
            <a href="<mtw:urlWithLoc loc="pt" />"><img src="images/brazil.gif" border="0" width="20" height="13" /></a>
117
            <a href="<mtw:urlWithLoc loc="en" />"><img src="images/usa.gif" width="20" height="13" border="0" /></a>
118
            &nbsp;&nbsp;&nbsp;
119
        </td>
12 soliveira 120
    </tr>
121
</table>
122
</div>
123
 
124
<hr />
125
 
126
<div id="leftColumn"><mtw:isLogged>
127
    <mtw:hasAuthorization groups="admin, editor">
26 soliveira 128
        <div style="text-align: right; padding-right: 8px; padding-top: 6px;"><a href="#" onclick="return showEditLeftColumnDialog('LeftColumn');" title="<k:editTooltip name="leftColumn" />">Edit</a></div>
12 soliveira 129
    </mtw:hasAuthorization>
130
</mtw:isLogged>
20 soliveira 131
<div id="navcolumn">
132
    <div>
22 soliveira 133
    <mtw:out value="leftColumn.body" />
20 soliveira 134
    </div>
135
<br />
12 soliveira 136
</div>
137
 
138
</div>
139
 
140
<div id="bodyColumn">
24 soliveira 141
    <mtw:out value="bodyColumn.body" />
12 soliveira 142
</div>
143
 
144
<div class="clear">
145
<hr />
146
</div>
147
 
148
<div id="footer">
149
<div class="xright">Copyright  2011</div>
150
<div class="clear">
151
<hr />
152
</div>
153
</div>
154
 
155
</body>
156
</html>