Note that there are some explanatory texts on larger screens.

plurals
  1. PObare metal wicket/tomcat HelloWorld example
    primarykey
    data
    text
    <p>I'm a wicket newbie and would like to deploy the simple well-known helloworld from wicket-examples but without IDE, ant or maven. What I've done:</p> <p>web.xml:</p> <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt; &lt;web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" version="2.4"&gt; &lt;display-name&gt;Wicket Examples&lt;/display-name&gt; &lt;filter&gt; &lt;filter-name&gt;HelloWorldApplication&lt;/filter-name&gt; &lt;filter-class&gt;org.apache.wicket.protocol.http.WicketFilter&lt;/filter-class&gt; &lt;init-param&gt; &lt;param-name&gt;applicationClassName&lt;/param-name&gt; &lt;param-value&gt;HelloWorldApplication&lt;/param-value&gt; &lt;/init-param&gt; &lt;/filter&gt; &lt;filter-mapping&gt; &lt;filter-name&gt;HelloWorldApplication&lt;/filter-name&gt; &lt;url-pattern&gt;/*&lt;/url-pattern&gt; &lt;/filter-mapping&gt; &lt;/web-app&gt; </code></pre> <p>HelloWorld.html:</p> <pre><code>&lt;html&gt; &lt;body&gt; &lt;span wicket:id="message"&gt;Message goes here!&lt;/span&gt; &lt;/body&gt; &lt;/html&gt; </code></pre> <p>HelloWorld.java:</p> <pre><code>import org.apache.wicket.markup.html.WebPage; import org.apache.wicket.markup.html.basic.Label; public class HelloWorld extends WebPage { public HelloWorld() { add(new Label("message", "Hello World!")); } } </code></pre> <p>HelloWorldApplication.java:</p> <pre><code>import org.apache.wicket.protocol.http.WebApplication; public class HelloWorldApplication extends WebApplication { public Class getHomePage() { return HelloWorld.class; } } </code></pre> <p>wicket-HelloWorld.war:</p> <pre><code>WEB-INF/ WEB-INF/web.xml WEB-INF/classes/ WEB-INF/classes/HelloWorldApplication.class WEB-INF/classes/HelloWorld.class WEB-INF/classes/HelloWorld.html WEB-INF/lib/ WEB-INF/lib/wicket-1.4.15.jar WEB-INF/lib/slf4j-api.jar </code></pre> <p>I'm not sure if I need slf4j-api.jar for this simple example</p> <p>When deployed to tomcat <a href="http://localhost:8080/wicket-HelloWorld/" rel="nofollow">http://localhost:8080/wicket-HelloWorld/</a> gives:</p> <p>The requested resource () is not available</p> <p>What I'm doing wrong?</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload