Re: JDeveloper and Wicket

2007-11-06 Thread johnnyGRE

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-nameconfiguration/param-name
param-valuedevelopment/param-value
  /context-param

filter
filter-nameHelloWorldApplication/filter-name

filter-classorg.apache.wicket.protocol.http.WicketFilter/filter-class
init-param
  param-nameapplicationClassName/param-name
  param-valuemypackage.HelloWorldApplication/param-value
/init-param
/filter


filter-mapping
filter-nameHelloWorldApplication/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
titleWicket 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
titleWicket examples/title
link rel=stylesheet type=text/css href=style.css/
/head
body
p
h1Wicket Example/h1
table
trtd align=right
 helloworld helloworld /tdtd - 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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: JDeveloper and Wicket

2007-11-01 Thread hillj2


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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]