/** * @author Kogonuso * @since 09/03/13 * */ import com.kogonuso.JLevel; public class Transition extends JLevel{ /*This method demonstrates how JLevel 2.0 can be written using only methods * instead of variables as in the content in the method * below it is your choice to pick the method you prefer and stick to it*/ protected String processRequest(){ String[] document ={ doctype(), html( head( title(t("JavaScript testing in JLevel")), includeStyle("stylesheet1.css"), attachJQuery("//ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js") ), body( div(id$("mainContent"), div(id$("nav"),br, //header and navigation called as a separate method headerAndNavigation(), br7, //menu a dl(class$("dropdown"), dt( id$("one-ddheader"),onmouseover$("ddMenu('one',1)"), onmouseout("ddMenu('one',-1)"),t("Menu One")), dd( id$("one-ddcontent"),onmouseover$("cancelHide('one')"), onmouseout("ddMenu('one',-1)"), ul( li(a (href$("#"),class$("underline"), t(" Item 1"))), li(a (href$("#"),class$("underline"), t("Item 2" ))), li(a( href$("#"),class$("underline"), t("Item 3") )), li(a(href$("#"),class$("underline"), t(" Item 4" ))), li(a(href$("#"),t("Item 5"))) ))), // //menu 2 dl(class$("dropdown"), dt( id$("two-ddheader"),onmouseover$("ddMenu('two',1)"), onmouseout("ddMenu('two',-1)"),t("Menu two")), dd( id$("two-ddcontent"),onmouseover$("cancelHide('two')"), onmouseout("ddMenu('two',-1)"), ul( li(a(href$("#"),class$("underline"),t("Item 1"))), li(a(href$("#"),class$("underline"),t("Item 2"))), li(a(href$("#"),class$("underline"),t(" Item 3"))), li(a(href$("#"),class$("underline"),t("Item 4"))), li(a(href$("#"),t("Item 5"))) ))), //menu3 //menu 2 dl(class$("dropdown"), dt( id$("three-ddheader"),onmouseover$("ddMenu('three',1)"), onmouseout("ddMenu('three',-1)"),t("Menu three")), dd( id$("three-ddcontent"),onmouseover$("cancelHide('three')"), onmouseout("ddMenu('three',-1)"), ul( li(a(href$("#"),class$("underline"),t("Item 1"))), li(a(href$("#"),class$("underline"),t("Item 2"))), li(a(href$("#"),class$("underline"),t("Item 3"))), li(a(href$("#"),class$("underline"),t("Item 4"))), li(a(href$("#"),t(" Item 5"))) ))), div("margin-left:30px;clear:both;", //Content area p("font-weight:900;color:green;",t(br+"Pure JLevel tag free Java made possible Html page")), pre(big(t("Get Ready for JLevel 2.0 - the simple tag free html java code library"+br+ "Go ahead and start forgetting what they taught you regarding counting HTML " +br+ "Tags both in web Development and java coding as these will become obsolete with JLevel 2.0."+br+ "It will provide experience that will seem fulfilling just like when web 2.0 took over the norm" +br+ "of WWW/Internet interaction and remained so today."+br+ "Nothing new to learn if you already know Java and Html. Your knowledge of JLevel 1.0.0 Beta " +br+ "WILL NOT BE useful with JLevel 2.0 as this is totally re-engineered library."+br+ "The purpose is still the same - to make programing and web development never feel like a drag " +br+ "anymore for developer that uses Html,Css JavaScript,jQuery and other scripts."+br+ "It will be simple that you will forget that Html ever has close set (tags). That is you will " +br+ "never worry about closing the open tag that takes attributes or in-line style and closing tag " +br+ "at all, all these have be automated. Furthermore,all self closing tags are have been taken care of."+br+ "Watch out for the preview code this week!"))) ))),br2, //footer method footer(), insertScript("C:/Users/Kogonuso/Desktop/Portables/Sites/Servlet+JSP/Test/WebContent/dropdown.js"), insertScript("C:/Users/Kogonuso/Desktop/Portables/Sites/Servlet+JSP/Test/WebContent/js2.js") )) }; saveAsHtml("transition", level(document)); return(level(document)); } /*This method demonstrates how JLevel 2.0 can be written using only variable instead of methods as in the content above * it is your choice to pick the method you prefer and stick to it*/ protected String headerAndNavigation(){ String[] headerNav ={ //header div("width:1000px;height:70px;", id$("header"), h1(id$("head"),a(href$("#"), t("JLevel 2.0 - Java Library"))) ), //the navigation bar sdiv,"width:1000px;height:60px;line-height:50px;background-color:#0D2A4F;margin:auto;",ct, odiv,id$,"navdiv",ct, oul,id$,"nav",ct, cli,aHref,"#",ct,"Home",ea,eli, cli,aHref,"#",ct,"JLevel v2.0",ea,eli, cli, aHref,"http://jlevel4java.blogspot.co.nz/",ct,"Products",ea, oul,class$,"child",ct, cli,aHref,"#",ct,"Animation",ea,eli, cli,aHref,"#",ct,"Transition",ea,eli, cli,aHref,"#",ct,"Content",ea,eli, cli,aHref,"#",ct,"Speakers",ea, cul, cli,aHref,"#",ct,"10 watt",ea,eli, cli,aHref,"#",ct,"20 watt",ea,eli, cli,aHref,"#",ct,"30 watt",ea,eli, eul, cli, cli,aHref,"#",ct,"Random Equipment",ea,eli, eul, eli, cli, aHref,"http://kogonuso.blogspot.co.nz/",ct,"Services",ea, oul,class$,"child",ct, cli,aHref,"#",ct,"Repairs",ea,eli, cli,aHref,"#",ct,"Installations",ea,eli, cli,aHref,"#",ct,"Setups",ea,eli, eul, eli, cli,aHref,"http://jlevel4java.blogspot.com/p/about.html",ct,"About",ea,eli, cli,aHref,"http://jlevel4java.blogspot.com/p/spport.html",ct,"Contact",ea,eli, eul, ediv,ediv }; return level(headerNav); } /*One of short methods to show how methods can be used inside a JLevel document former method*/ protected String footer(){ String[] footer ={ cdiv,ccenter,ofooter,id$,"footer",ct,"© JLevel 2013. All Rights Reserved!",efooter,ecenter,ediv, }; return level(footer); } /*One of short methods to show how methods can be used inside a JLevel document former method*/ protected String advert(){ return br6+"That's what JLevel can do for you!"; } public static void main(String[] args) { Transition t = new Transition(); t.processRequest(); } }
Search
Search Result
Demo web page written using JLevel 2.0
Subscribe to:
Posts (Atom)
No comments:
Post a Comment