You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by johnnyGRE <jo...@gmail.com> on 2007/11/01 11:05:54 UTC

JDeveloper and Wicket

Hello,
How can I setup wicket on JDeveloper?
Can anyone help with a step-by-step guide specific on JDev?
I have tried but no luck so far.

Thanks for your time,
John
-- 
View this message in context: http://www.nabble.com/JDeveloper-and-Wicket-tf4730313.html#a13525928
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: JDeveloper and Wicket

Posted by johnnyGRE <jo...@gmail.com>.
Ok I have been able to setup wicket 1.2.6 to jdev and produce a helloworld of
my own.
After I tried it with 1.3 beta 4, even though I made the changes proposed to
migrate I could not run it successgully (using JDeveloper).
I will provide the web.xml, HelloWorld.java, HelloWorld.html,
HelloWorldApplication.java and index.html of my example, just in case there
is someone that can help me, or has an idea for my problem. When i run the
index page, it cannot find the page (http 404).

Web.xml
__________________________________
web-app>
  <context-param>
	<param-name>configuration</param-name>
	<param-value>development</param-value>
  </context-param>

        <filter>
  		<filter-name>HelloWorldApplication</filter-name>
		<filter-class>org.apache.wicket.protocol.http.WicketFilter</filter-class>
		<init-param>
		  <param-name>applicationClassName</param-name>
		  <param-value>mypackage.HelloWorldApplication</param-value>
		</init-param>
	</filter>


	<filter-mapping>
		<filter-name>HelloWorldApplication</filter-name>
		<url-pattern>/helloworld/*</url-pattern>
	</filter-mapping>
</web-app>
___________________________________

HelloWorld.java
_____________________________________
package mypackage;

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!"));
    }
}
__________________________________
HelloWorld.html
_________________________________
<?xml version="1.0" encoding="UTF-8"?>
<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
    <title>Wicket Examples - helloworld</title>
    <link rel="stylesheet" type="text/css" href="style.css"/>
</head>
<body>
    Message goes here
</body>
</html>
_______________________________
index.html
_________________________________
<html xmlns:wicket="http://wicket.apache.org/">
	<head>
		<title>Wicket examples</title>
    <link rel="stylesheet" type="text/css" href="style.css"/>
	</head>
	<body>
    <p>
	<h1>Wicket Example</h1>
		<table>
	        <tr><td align="right">
                 helloworld helloworld </td><td> - Everyone's favorite
example</td></tr>
                
	    </table>
    </p>
  </body>
</html>
__________________________________________

PS. Index is located on <home> and all other under mypackage.




-- 
View this message in context: http://www.nabble.com/JDeveloper-and-Wicket-tf4730313.html#a13609213
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: JDeveloper and Wicket

Posted by hillj2 <Hi...@michigan.gov>.

johnnyGRE wrote:
> 
> Hello,
> How can I setup wicket on JDeveloper?
> Can anyone help with a step-by-step guide specific on JDev?
> I have tried but no luck so far.
> 

I'm not sure what fancy setup you're looking for, but I've done a little
wicket in JDev (Version 10.1.3.2).  Basically I add the wicket jar to the
list of libraries, and then go into project properties and under the
Compiler options add all the extensions of files in my classpath to the list
of extensions under the "Copy File Types to Output Directory" option (.html,
.properties, etc.).  This makes sure files like you markup files stay in the
proper directory for deployment.  Then I just develop like I would any other
web app.

The only annoying part is when I add a new html file (make sure you add it
to the proper directory on your classpath and not the default web folder,
unless your wicket is setup to look for markup on something other than the
classpath).  Since I'm not adding to the default web folder, JDev decides to
add that directory to the list of resources.  Simple to remove in the
project properties (under Project Content > Resources), but annoying to have
to do it for each new html file.

Hopefully that helps.  Good luck.

Joel

-- 
View this message in context: http://www.nabble.com/JDeveloper-and-Wicket-tf4730313.html#a13527949
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org