Kawai Wiki

Rev

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