Kawai Wiki

Compare Revisions

Ignore whitespace Rev 30 → Rev 31

/trunk/src/main/java/org/kawai/model/Page.java
5,6 → 5,8
public class Page {
public static final String LEFT_COLUMN = "LeftColumn";
public static final String CSS = "CSS";
public static final String PRINT_CSS = "PrintCSS";
private int id;
private String name;
/trunk/src/main/java/org/kawai/AppManager.java
207,6 → 207,12
action("/Page", PageAction.class, "editPage")
.on(UPDATED, redir(indexAction));
action("/GenerateCSS", PageAction.class, "getCSS")
.on(SUCCESS, fwd("/generate_css.jsp"));
action("/GenerateCSS", PageAction.class, "getPrintCSS")
.on(SUCCESS, fwd("/generate_css.jsp"));
}
////////////////////////////////////////////////////////////////////////////////
/trunk/src/main/java/org/kawai/action/PageAction.java
10,6 → 10,7
private static final String LEFT_COLUMN_KEY = "leftColumn";
private static final String BODY_COLUMN_KEY = "bodyColumn";
private static final String CSS_KEY = "css";
public PageAction(UserDAO userDAO, PageDAO pageDAO) {
super(userDAO, pageDAO);
30,6 → 31,15
output.setValue(LEFT_COLUMN_KEY, lc);
}
private Page loadCSS() {
return pageDAO.loadByName(Page.CSS, Language.ENGLISH); // we only have one CSS (in English)...
}
private void setCSS() {
Page css = loadCSS();
output.setValue(CSS_KEY, css);
}
private Page loadFrontPage(Language lang) {
Page page = pageDAO.loadFrontPage(lang);
if (page == null) {
50,7 → 60,19
return AJAX;
}
public String getCSS() {
setCSS();
return SUCCESS;
}
public String getPrintCSS() {
Page page = pageDAO.loadByName(Page.PRINT_CSS, Language.ENGLISH);
output.setValue(CSS_KEY, page);
return SUCCESS;
}
public String execute() {
setCSS();
setLeftColumn();
String name = input.getString("name");
Page page = null;
71,6 → 93,10
String name = input.getString("name");
int languageId = input.getInt("languageId");
Language lang = Language.fromId(languageId);
if (name.equals("CSS")) {
// does not make sense to have CSS in different languages... (well, maybe it does, but we do NOT want to maintain more than one CSS)
lang = Language.ENGLISH;
}
Page page = pageDAO.loadByName(name, lang);
if (page != null) {
input.inject(page);
/trunk/src/main/webapp/style/kawai.css
File deleted
/trunk/src/main/webapp/style/print.css
File deleted
/trunk/src/main/webapp/WEB-INF/db/kawai.sql
50,7 → 50,7
--
 
 
INSERT INTO `Pages` VALUES (1,'LeftColumn',1,'F','T',NULL,' <h3>Introduction </h3>\r\n <ul>\r\n <li class=\"none\">\r\n <a href=\"http://www.oglobo.com.br\" class=\"large\">O Globo</a>\r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n \r\n <h3>Section 1</h3>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n\r\n <h4>Section 2</h4>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n \r\n <h4>Section 2</h4>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>\r\n \r\n \r\n <h5>Section 3</h5>\r\n <br/>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>\r\n \r\n <h5>Section 3</h5>\r\n <br/>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>',2,'2011-10-25 04:08:41',1,'2011-10-25 01:32:07'),(2,'LeftColumn',2,'F','T',NULL,' <h3>Introdução </h3>\r\n <ul>\r\n <li class=\"none\">\r\n <a href=\"http://www.oglobo.com.br\" class=\"large\">OGlobo</a>\r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n \r\n <h3>Section 1</h3>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n\r\n <h4>Section 2</h4>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n \r\n <h4>Section 2</h4>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>\r\n \r\n \r\n <h5>Section 3</h5>\r\n <br/>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>\r\n \r\n <h5>Section 3</h5>\r\n <br/>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>',2,'2011-10-25 03:54:20',1,'2011-10-25 01:32:07'),(3,'Intro',1,'T','F','Welcome to the Mentawai Web Framework','<h1>News here:</h1>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h2> News </h2>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h3> News </h3>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h4> News </h4>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h5> News </h5>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n',2,'2011-10-25 03:54:44',2,'2011-10-25 01:32:07'),(4,'Intro',2,'T','F','Bem-vindo ao Mentawai Web Framework','<h1>Notícias</h1>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h2> Notícias </h2>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h3> News </h3>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h4> News </h4>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h5> News </h5>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n',2,'2011-10-25 03:54:34',2,'2011-10-25 01:32:07');
INSERT INTO `Pages` VALUES (1,'LeftColumn',1,'F','T',NULL,' <h3>Introduction </h3>\r\n <ul>\r\n <li class=\"none\">\r\n <a href=\"http://www.oglobo.com.br\" class=\"large\">O Globo</a>\r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n \r\n <h3>Section 1</h3>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n\r\n <h4>Section 2</h4>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n \r\n <h4>Section 2</h4>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>\r\n \r\n \r\n <h5>Section 3</h5>\r\n <br/>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>\r\n \r\n <h5>Section 3</h5>\r\n <br/>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>',2,'2011-10-25 04:08:41',1,'2011-10-25 01:32:07'),(2,'LeftColumn',2,'F','T',NULL,' <h3>Introdução </h3>\r\n <ul>\r\n <li class=\"none\">\r\n <a href=\"http://www.oglobo.com.br\" class=\"large\">OGlobo</a>\r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n \r\n <h3>Section 1</h3>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"large\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n\r\n <h4>Section 2</h4>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n \r\n <h4>Section 2</h4>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"medium\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>\r\n \r\n \r\n <h5>Section 3</h5>\r\n <br/>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>\r\n \r\n <h5>Section 3</h5>\r\n <br/>\r\n <ul>\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 1</a>\r\n \r\n </li>\r\n \r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 2</a>\r\n \r\n </li>\r\n\r\n <li class=\"none\">\r\n \r\n <a href=\"index.jsp\" class=\"small\">Link 3</a>\r\n \r\n </li>\r\n </ul>\r\n <br/>',2,'2011-10-25 03:54:20',1,'2011-10-25 01:32:07'),(3,'Intro',1,'T','F','Welcome to the Mentawai Web Framework','<h1>News here:</h1>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h2> News </h2>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h3> News </h3>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h4> News </h4>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h5> News </h5>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n',2,'2011-10-25 03:54:44',2,'2011-10-25 01:32:07'),(4,'Intro',2,'T','F','Bem-vindo ao Mentawai Web Framework','<h1>Notícias</h1>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h2> Notícias </h2>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h3> News </h3>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h4> News </h4>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n\r\n<h5> News </h5>\r\n<ul>\r\n <li>Teste 1</li>\r\n <li>Teste 2</li>\r\n <li>Teste 3</li>\r\n <li>Teste 4</li>\r\n</ul>\r\n<br />\r\n',2,'2011-10-25 03:54:34',2,'2011-10-25 01:32:07'),(5,'CSS',1,'F','T',NULL,'/************************/\r\n/* CSS BASE STARTS */\r\n/************************/\r\nbody {\r\n margin: 0px;\r\n padding: 0px 0px 10px 0px;\r\n}\r\nimg {\r\n border:none;\r\n}\r\ntable {\r\n padding:0px;\r\n width: 100%;\r\n margin-left: -2px;\r\n margin-right: -2px;\r\n}\r\nacronym {\r\n cursor: help;\r\n border-bottom: 1px dotted #feb;\r\n}\r\ntable.bodyTable th, table.bodyTable td {\r\n padding: 2px 4px 2px 4px;\r\n vertical-align: top;\r\n}\r\ndiv.clear{\r\n clear:both;\r\n visibility: hidden;\r\n}\r\ndiv.clear hr{\r\n display: none;\r\n}\r\n\r\niframe { \r\nwidth: 100%;\r\n_width: 80%; /* IE 6 */\r\n}\r\n\r\n#projectLogo {\r\n font-size: xx-large; \r\n font-weight: bold;\r\n}\r\n#organizationLogo img, #projectLogo img, #projectLogo span{\r\n margin: 8px;\r\n}\r\n#projectLogo span{\r\n border: 1px solid;\r\n padding: 4px 10px 4px 10px;\r\n background-color: #eee;\r\n cursor: pointer;\r\n}\r\n.xleft, #organizationLogo img{\r\n float:left;\r\n} \r\n.xright, #projectLogo img, #projectLogo span{\r\n float:right;\r\n text-shadow: #7CFC00;\r\n}\r\n#banner {\r\n border-bottom: 1px solid #fff;\r\n}\r\n#banner img {\r\n border: none;\r\n}\r\n#footer, #breadcrumbs {\r\n padding: 3px 10px 3px 10px;\r\n}\r\n#leftColumn {\r\n width: 18%;\r\n float:left;\r\n}\r\n#bodyColumn {\r\n margin-left: 20%;\r\n margin-right: 1%;\r\n}\r\n#navcolumn {\r\n padding: 8px 4px 0 8px;\r\n}\r\n#navcolumn h5, #navcolumn ul {\r\n margin: 0;\r\n padding: 0;\r\n font-size: small;\r\n}\r\n#navcolumn li {\r\n list-style-type: none;\r\n background-image: none;\r\n background-repeat: no-repeat;\r\n background-position: 0 0.4em;\r\n padding-left: 16px;\r\n list-style-position: ouside;\r\n line-height: 1.2em;\r\n font-size: smaller;\r\n}\r\n#navcolumn li.expanded {\r\n background-image: url(../images/expanded.gif);\r\n}\r\n#navcolumn li.collapsed {\r\n background-image: url(../images/collapsed.gif);\r\n}\r\n#poweredBy {\r\n text-align: center;\r\n}\r\n#navcolumn img {\r\n margin-top: 10px;\r\n margin-bottom: 3px;\r\n}\r\n#poweredBy img {\r\n display:block;\r\n margin: 20px 0 20px 17px;\r\n border: 1px solid black;\r\n width: 90px;\r\n height: 30px;\r\n}\r\n#search img {\r\n margin: 0px;\r\n display: block;\r\n}\r\n#search #q, #search #btnG {\r\n border: 1px solid #999;\r\n margin-bottom:10px;\r\n}\r\n#search form {\r\n margin: 0px;\r\n}\r\n#lastPublished {\r\n font-size: x-small;\r\n}\r\n.navSection {\r\n margin-bottom: 2px;\r\n padding: 8px;\r\n}\r\n.navSectionHead {\r\n font-weight: bold;\r\n font-size: x-small;\r\n}\r\n.section {\r\n padding: 4px;\r\n}\r\n#footer {\r\n font-size: x-small;\r\n}\r\n#breadcrumbs {\r\n font-size: x-small;\r\n margin: 0pt;\r\n}\r\n.source {\r\n padding: 12px;\r\n margin: 1em 7px 1em 7px;\r\n}\r\n.source pre {\r\n margin: 0px;\r\n padding: 0px;\r\n}\r\n\r\n/****************************/\r\n/* CSS OVERRIDE STARTS HERE */\r\n/****************************/\r\n\r\nbody, td, select, input, li{\r\n font-family: Verdana, Helvetica, Arial, sans-serif;\r\n font-size: 13px;\r\n}\r\na {\r\n text-decoration: none;\r\n}\r\na:link {\r\n color:#36a;\r\n}\r\na:visited {\r\n color:#47a;\r\n}\r\na:active, a:hover {\r\n color:#69c;\r\n}\r\na.externalLink, a.externalLink:link, a.externalLink:visited, a.externalLink:active, a.externalLink:hover {\r\n background: url(../images/external.png) right center no-repeat;\r\n padding-right: 15px;\r\n}\r\na.newWindow, a.newWindow:link, a.newWindow:visited, a.newWindow:active, a.newWindow:hover {\r\n background: url(../images/newwindow.png) right center no-repeat;\r\n padding-right: 18px;\r\n}\r\n\r\n#bodyColumn h1 {\r\n padding: 4px 4px 4px 6px;\r\n border: 1px solid #999;\r\n color: #900;\r\n background-color: #ccc;\r\n font-weight:900;\r\n font-size: 28px;\r\n}\r\n\r\n#bodyColumn h2 {\r\n padding: 4px 4px 4px 6px;\r\n border: 1px solid #999;\r\n color: #900;\r\n background-color: #ddd;\r\n font-weight:900;\r\n font-size: 24px;\r\n}\r\n\r\n#bodyColumn h3 {\r\n padding: 4px 4px 4px 6px;\r\n border: 1px solid #aaa;\r\n color: #900;\r\n background-color: #eee;\r\n font-weight: normal;\r\n font-size: 20px;\r\n}\r\n#bodyColumn h4 {\r\n padding: 4px 4px 4px 6px;\r\n border: 1px solid #aaa;\r\n color: #900;\r\n background-color: #eee;\r\n font-weight: normal;\r\n font-size: 16px;\r\n}\r\n#bodyColumn h5 {\r\n padding: 4px 4px 4px 6px;\r\n border: 1px solid #aaa;\r\n color: #900;\r\n background-color: #fff;\r\n font-weight: normal;\r\n font-size: 14px;\r\n}\r\n\r\n\r\np {\r\n line-height: 1.3em;\r\n font-size: small;\r\n}\r\n#breadcrumbs {\r\n border-top: 1px solid #aaa;\r\n border-bottom: 1px solid #aaa;\r\n background-color: #ccc;\r\n}\r\n#leftColumn {\r\n margin: 10px 0 0 5px;\r\n border: 1px solid #999;\r\n background-color: #eee;\r\n}\r\n#navcolumn h3 {\r\n font-size: 14px;\r\n border-bottom: 1px solid #aaaaaa;\r\n padding-left: 4px;\r\n}\r\n#navcolumn h4 {\r\n font-size: 12px;\r\n border-bottom: 1px solid #aaaaaa;\r\n padding-left: 4px;\r\n}\r\n\r\n#navcolumn h5 {\r\n font-size: smaller;\r\n border-bottom: 1px solid #aaaaaa;\r\n padding-left: 4px;\r\n}\r\n\r\n#navcolumn .large {\r\n font-size: 14px;\r\n padding-bottom: 2px;\r\n}\r\n\r\n#navcolumn .medium {\r\n font-size: 13px;\r\n padding-bottom: 2px;\r\n}\r\n\r\n#navcolumn .small {\r\n font-size: 12px;\r\n padding-bottom: 2px;\r\n}\r\n#navcolumn li {\r\n padding-bottom: 2px;\r\n}\r\ntable.bodyTable th {\r\n color: white;\r\n background-color: #bbb;\r\n text-align: left;\r\n font-weight: bold;\r\n}\r\n\r\ntable.bodyTable th, table.bodyTable td {\r\n font-size: 1em;\r\n}\r\n\r\ntable.bodyTable tr.a {\r\n background-color: #ddd;\r\n}\r\n\r\ntable.bodyTable tr.b {\r\n background-color: #eee;\r\n}\r\n\r\n.source {\r\n border: 1px solid #999;\r\n}\r\n\r\n',2,'2011-10-25 04:54:03',1,'2011-10-25 01:32:07'),(6,'PrintCSS',1,'F','T',NULL,'',NULL,NULL,1,'2011-10-25 01:32:07');
 
 
--
135,4 → 135,4
 
 
 
-- Dump completed on 2011-10-24 23:09:18
-- Dump completed on 2011-10-24 23:54:14
/trunk/src/main/webapp/WEB-INF/web.xml
31,6 → 31,12
<servlet-name>Controller</servlet-name>
<url-pattern>*.mtw</url-pattern>
</servlet-mapping>
<!-- This is so we can generate CSS dynamically -->
<servlet-mapping>
<servlet-name>Controller</servlet-name>
<url-pattern>*.css</url-pattern>
</servlet-mapping>
 
<filter>
<filter-name>DebugFilter</filter-name>
/trunk/src/main/webapp/show_page.jsp
8,7 → 8,7
<title>Mentawai Web Framework</title>
 
<style type="text/css" media="all">
@import url("./style/kawai.css");
@import url("<mtw:contextPath/>/GenerateCSS.getCSS.css");
</style>
 
<meta http-equiv="imagetoolbar" content="no" />
16,7 → 16,7
 
<link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />
<link rel="icon" type="image/gif" href="/favicon.gif" />
<link rel="stylesheet" href="./style/print.css" type="text/css" media="print" />
<link rel="stylesheet" href="<mtw:contextPath/>/GenerateCSS.getPrintCSS.css" type="text/css" media="print" />
 
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<meta name="author" content="Sergio Oliveira Junior" />
112,6 → 112,7
<mtw:isLogged>
<a href="<mtw:contextPath/>/Page.create.mtw">Create New Page</a> |
<a href="<mtw:contextPath/>/Page.list.mtw">List Pages</a> |
<a href="#" onclick="return showEditPageDialog('CSS');" title="<k:editTooltip name="css" />">Edit CSS</a> |
<a href="<mtw:contextPath/>/Logout.mtw">Logout</a> (<mtw:out value="sessionUser.username" />)
</mtw:isLogged>
&nbsp;
/trunk/src/main/webapp/generate_css.jsp
New file
0,0 → 1,4
<%@page contentType="text/css" %>
<%@taglib prefix="mtw" uri="http://www.mentaframework.org/tags-mtw/"%>
 
<mtw:out value="css.body" />