aboutsummaryrefslogtreecommitdiff
path: root/src/main/webapp/WEB-INF
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2012-12-19 23:42:12 +0100
committerTrygve Laugstøl <trygvis@inamo.no>2012-12-19 23:42:12 +0100
commit79c6c1d042fdad06294f4db57c5b8c91b6a0e5d0 (patch)
tree815da28b8238bbe3bf44ef126fb79c0ffaf41de6 /src/main/webapp/WEB-INF
parent4abc880c4b9ce6888acab85c815514f3dd195fa4 (diff)
downloadesper-testing-79c6c1d042fdad06294f4db57c5b8c91b6a0e5d0.tar.gz
esper-testing-79c6c1d042fdad06294f4db57c5b8c91b6a0e5d0.tar.bz2
esper-testing-79c6c1d042fdad06294f4db57c5b8c91b6a0e5d0.tar.xz
esper-testing-79c6c1d042fdad06294f4db57c5b8c91b6a0e5d0.zip
o Adding a basic web app.
Diffstat (limited to 'src/main/webapp/WEB-INF')
-rw-r--r--src/main/webapp/WEB-INF/tags/common/footer.tagx9
-rw-r--r--src/main/webapp/WEB-INF/tags/common/head-element.tagx34
-rw-r--r--src/main/webapp/WEB-INF/tags/common/headjs.tagx10
-rw-r--r--src/main/webapp/WEB-INF/web.xml35
4 files changed, 88 insertions, 0 deletions
diff --git a/src/main/webapp/WEB-INF/tags/common/footer.tagx b/src/main/webapp/WEB-INF/tags/common/footer.tagx
new file mode 100644
index 0000000..7f686ee
--- /dev/null
+++ b/src/main/webapp/WEB-INF/tags/common/footer.tagx
@@ -0,0 +1,9 @@
+<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
+ <footer id="footer">
+ <div class="container">
+
+ <p>Footer, yo!</p>
+
+ </div>
+ </footer>
+</jsp:root>
diff --git a/src/main/webapp/WEB-INF/tags/common/head-element.tagx b/src/main/webapp/WEB-INF/tags/common/head-element.tagx
new file mode 100644
index 0000000..5321612
--- /dev/null
+++ b/src/main/webapp/WEB-INF/tags/common/head-element.tagx
@@ -0,0 +1,34 @@
+<!--suppress JspAbsolutePathInspection -->
+<jsp:root version="2.0"
+ xmlns:c="http://java.sun.com/jsp/jstl/core"
+ xmlns:jsp="http://java.sun.com/JSP/Page">
+ <jsp:output omit-xml-declaration="yes"/>
+ <jsp:directive.attribute name="title" type="java.lang.String" required="false"/>
+ <jsp:directive.attribute name="app" type="java.lang.String" required="false"/>
+
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+ <title><c:if test="${not empty title }">${title } - </c:if>Yeah</title>
+
+ <link type="text/css" rel="stylesheet" href="/external/bootstrap-2.2.2/css/bootstrap.css"/>
+
+ <script type="text/javascript" src="/external/headjs-0.99/head.min.js"><!-- --></script>
+ <script type="text/javascript">
+ head.js(
+ {jquery: "/external/jquery-1.8.3/jquery.js"},
+ {angularjs: "/external/angular-1.0.3/angular.js"},
+ {angularjsResource: "/external/angular-1.0.3/angular-resource.js"}
+ );
+ </script>
+ <script>var noCache = new Date().getTime();</script>
+
+ <jsp:doBody/>
+
+ <script type="text/javascript">
+ head.ready(function() {
+ angular.bootstrap(document, [<c:out value="${app}"/>]);
+ });
+ </script>
+ </head>
+
+</jsp:root>
diff --git a/src/main/webapp/WEB-INF/tags/common/headjs.tagx b/src/main/webapp/WEB-INF/tags/common/headjs.tagx
new file mode 100644
index 0000000..4e39e63
--- /dev/null
+++ b/src/main/webapp/WEB-INF/tags/common/headjs.tagx
@@ -0,0 +1,10 @@
+<jsp:root xmlns:c="http://java.sun.com/jsp/jstl/core"
+ xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0">
+ <jsp:directive.tag body-content="empty"/>
+ <jsp:directive.attribute name="label" type="java.lang.String" required="true"/>
+ <jsp:directive.attribute name="resource" type="java.lang.String" required="true"/>
+
+ <script type="text/javascript">
+ head.js({'${label}':'<c:out value="${resource}"/>?noCache=' + noCache});
+ </script>
+</jsp:root>
diff --git a/src/main/webapp/WEB-INF/web.xml b/src/main/webapp/WEB-INF/web.xml
new file mode 100644
index 0000000..de37fae
--- /dev/null
+++ b/src/main/webapp/WEB-INF/web.xml
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
+ version="3.0">
+ <filter>
+ <filter-name>Jersey</filter-name>
+ <!--
+ <filter-class>org.glassfish.jersey.servlet.ServletContainer</filter-class>
+ -->
+ <filter-class>com.sun.jersey.spi.container.servlet.ServletContainer</filter-class>
+ <init-param>
+ <param-name>javax.ws.rs.Application</param-name>
+ <param-value>io.trygvis.esper.testing.web.JerseyApplication</param-value>
+ </init-param>
+ <init-param>
+ <param-name>jersey.config.servlet.filter.staticContentRegex</param-name>
+ <param-value>/(image|css|external)/.*</param-value>
+ </init-param>
+ <init-param>
+ <param-name>com.sun.jersey.config.feature.FilterForwardOn404</param-name>
+ <param-value>true</param-value>
+ </init-param>
+ <init-param>
+ <param-name>com.sun.jersey.api.json.POJOMappingFeature</param-name>
+ <param-value>true</param-value>
+ </init-param>
+ </filter>
+ <filter-mapping>
+ <filter-name>Jersey</filter-name>
+ <url-pattern>/*</url-pattern>
+ </filter-mapping>
+ <welcome-file-list>
+ <welcome-file>index.jspx</welcome-file>
+ </welcome-file-list>
+</web-app>