RE: Error during start of wicket application

2012-04-11 Thread Alex Rass
Seems like a classpath issue.
Make sure that all the wicket jars that you need are included in your path.

- Alex 

-Original Message-
From: André Schütz [mailto:andre-p...@gmx.de] 
Sent: Thursday, February 23, 2012 12:13 PM
To: users@wicket.apache.org
Subject: Error during start of wicket application

Hello,

I get the following error message during a start of the tomcat server with a 
clean packed wicket application:

/**
 * BEGIN
 */

Exception in thread Thread-2 java.lang.NoClassDefFoundError: 
org/apache/wicket/ApplicationListenerCollection$2
at 
org.apache.wicket.ApplicationListenerCollection.onBeforeDestroyed(ApplicationListenerCollection.java:44)
at org.apache.wicket.Application.internalDestroy(Application.java:639)
at 
org.apache.wicket.protocol.http.WebApplication.internalDestroy(WebApplication.java:563)
at 
org.apache.wicket.protocol.http.WicketFilter.destroy(WicketFilter.java:478)
at 
org.apache.catalina.core.ApplicationFilterConfig.release(ApplicationFilterConfig.java:357)
at 
org.apache.catalina.core.StandardContext.filterStop(StandardContext.java:3873)
at 
org.apache.catalina.core.StandardContext.stop(StandardContext.java:4605)
at org.apache.catalina.core.ContainerBase.stop(ContainerBase.java:1098)
at org.apache.catalina.core.ContainerBase.stop(ContainerBase.java:1098)
at org.apache.catalina.core.StandardEngine.stop(StandardEngine.java:448)
at 
org.apache.catalina.core.StandardService.stop(StandardService.java:584)
at org.apache.catalina.core.StandardServer.stop(StandardServer.java:744)
at org.apache.catalina.startup.Catalina.stop(Catalina.java:643)
at 
org.apache.catalina.startup.Catalina$CatalinaShutdownHook.run(Catalina.java:687)
Caused by: java.lang.ClassNotFoundException: 
org.apache.wicket.ApplicationListenerCollection$2
at 
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1484)
at 
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1329)
... 14 more

/**
 * END
 */

Any ideas about this error?

Thanks,
Andre
--
Empfehlen Sie GMX DSL Ihren Freunden und Bekannten und wir belohnen Sie mit bis 
zu 50,- Euro! https://freundschaftswerbung.gmx.de

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



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



tomcat deployment issues

2012-04-11 Thread Alex Rass
If someone could help me out with this issue, that would be awesome.

Currently:
Deploying on Tomcat 6.

Default deploy folder is webapps
webapps/ROOT is where my 1st wicket app is (lets call it App1)
webapps.web2 is another Host record for a different URL.
webapps.web2/app2 is my wicket app #2

No matter what I tried, app#2 doesn't get started (but servlets from same 
context work fine).
When I go to the url, it says:

java.lang.IllegalStateException: Application with name 'App2' already exists.'
org.apache.wicket.Application.setName(Application.java:854)
org.apache.wicket.protocol.http.WicketFilter.init(WicketFilter.java:337)

org.apache.wicket.protocol.http.WicketServlet.init(WicketServlet.java:271)
javax.servlet.GenericServlet.init(GenericServlet.java:212)
...

I tried renaming it to App3 (in web.xml and I get same message except it says 
App3).
I checked all the web.xml files on the server, no other one has App2 in it.

I have lib folders under each app. I don't share anything beside DB drivers in 
Tomcat's lib folder.
I have Wicket 1.5.4 for App1 and 1.5.5 for App2 (donno if that makes a diff).

Any ideas?

Regards,
- Alex.



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



developers needed

2011-06-28 Thread Alex Rass
Hi.

Can use a wicket developer or two for a 3-4 week project.
Needs to be able to work legally in US, sign a Non-Disclosure Agreement
(NDA) and have an SSN# for a W9 form (to do 1099).

Work from home.

Gotta be able to show me some wicket work (with source samples) you did in
the past.

Work would start asap. Don't care if you work nights and weekends, but you
gotta be available to do the work. 

Later on, there will be other projects and occasional maintenance work.

Please send me your rates and source samples.

Email directly to above address as I don't read all the messages in these
forums all that often these days.

We are a small company in NJ that does development. Mostly in Java.

Sincerely,
- Alex.


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



urls after a form submission

2010-10-06 Thread Alex Rass
Hi.

After an on-page (wicket) form is submitted, the followed url doesn't follow
the page's URL encoding strategy (QueryStringUrlCodingStrategy or any
others).

It just becomes http://site.com/?wicket...; and loses original page

Could someone please tell me if there's a way to fix it easily? 
Is this a bug that should be fixed or a normal behavior?

I REALLY need this working. Otherwise a 200 page site becomes a class
nightmare.

- Alex 


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



RE: urls after a form submission

2010-10-06 Thread Alex Rass
But that breaks the common sense of strategy, doesn't it?
And if it works special for HybridUrlCodingStrategy, then it should also
work with the other ones, right? Consistency rule makes it a bug, right?

HybridUrlCodingStrategy  messes with the original name. I'd rather use
QueryStringUrlCodingStrategy that keeps urls proper. It's almost there
with using wicket parameter, shouldn't it be fully compliant with the
strategy of the parent? It just makes sense (to me).

- Alex 

-Original Message-
From: Jeremy Thomerson [mailto:jer...@wickettraining.com] 
Sent: Wednesday, October 06, 2010 8:13 PM
To: users@wicket.apache.org
Subject: Re: urls after a form submission

On Wed, Oct 6, 2010 at 6:59 PM, Alex Rass a...@itbsllc.com wrote:

 Hi.

 After an on-page (wicket) form is submitted, the followed url doesn't 
 follow the page's URL encoding strategy (QueryStringUrlCodingStrategy 
 or any others).

 It just becomes http://site.com/?wicket...; and loses original page

 Could someone please tell me if there's a way to fix it easily?
 Is this a bug that should be fixed or a normal behavior?

 I REALLY need this working. Otherwise a 200 page site becomes a class 
 nightmare.

 - Alex


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


It's standard behavior.  You're redirecting to a stateful page - with the
state of the form - when you submit the form.  If you want a bookmarkable
URL that still has state, use HybridUrlCodingStrategy.

--
Jeremy Thomerson
http://www.wickettraining.com


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



multiple html pages to 1 class

2010-09-28 Thread Alex Rass
I know this has been raised tons of times,
But has anyone ever figured out: how to do this and not screw up page
versioning?

Any sort of CMS would need this.

I am ok with going to 1.5.M2 for this, btw, if that solves it.

- Alex.


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



RE: multiple html pages to 1 class

2010-09-28 Thread Alex Rass
Thanks, Igor.

That's what I did.
BUT as soon as I hit form submit - it does a round-trip and loses the page
part in the URL, and I am down to 
site.com/?wicket...
from having a nice site.com/page.html (and using getRequest() to grab the
page name).
So I have no way to know which page I am actually on anymore :)

- Alex


-Original Message-
From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com] 
Sent: Tuesday, September 28, 2010 11:46 AM
To: users@wicket.apache.org
Subject: Re: multiple html pages to 1 class

let your page implement IMarkupResourceStreamProvider and
IMarkupCacheKeyProvider and return whatever html you want, anything will do
it as long as it matches component hierarchy.

-igor

On Tue, Sep 28, 2010 at 7:40 AM, Alex Rass a...@itbsllc.com wrote:
 I know this has been raised tons of times, But has anyone ever figured 
 out: how to do this and not screw up page versioning?

 Any sort of CMS would need this.

 I am ok with going to 1.5.M2 for this, btw, if that solves it.

 - Alex.


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



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



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



RE: multiple html pages to 1 class

2010-09-28 Thread Alex Rass
Yeah, smart approach, and I thought about that...

It's no good because the URL becomes unusable right after.
And I would need custom handling inside each form (or having to sub-class
every form I use).
And hitting reload or moving the tab to another window will most likely
break it in some browsers.

I even tried applying the QueryStringUrlCodingStrategy but it loses the page
name as soon as you submit the form. Seems like a bug to me.  One that
prevents me from having a nice 1-class handler :(

HybridUrlCodingStrategy has been used in some hacky tutorials, but you get
the version at the end or the page name which makes everything fall apart.
So I suspect solution is to fix the post form refresh of the url for the
BookmarkablePageRequestTargetUrlCodingStrategy and/or for the
QueryStringUrlCodingStrategy

Or I am open to other suggestions.

- Alex Rass


-Original Message-
From: Jeremy Thomerson [mailto:jer...@wickettraining.com] 
Sent: Tuesday, September 28, 2010 1:00 PM
To: users@wicket.apache.org
Subject: Re: multiple html pages to 1 class

If you're getting what template to use from the PageParameters, and then
submitting a form, save it in a field in the page when you pull it from the
PageParameters.

On Tue, Sep 28, 2010 at 11:53 AM, Alex Rass a...@itbsllc.com wrote:

 Thanks, Igor.

 That's what I did.
 BUT as soon as I hit form submit - it does a round-trip and loses the 
 page part in the URL, and I am down to site.com/?wicket...
 from having a nice site.com/page.html (and using getRequest() to grab 
 the page name).
 So I have no way to know which page I am actually on anymore :)

 - Alex


 -Original Message-
 From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com]
 Sent: Tuesday, September 28, 2010 11:46 AM
 To: users@wicket.apache.org
 Subject: Re: multiple html pages to 1 class

 let your page implement IMarkupResourceStreamProvider and 
 IMarkupCacheKeyProvider and return whatever html you want, anything 
 will do it as long as it matches component hierarchy.

 -igor

 On Tue, Sep 28, 2010 at 7:40 AM, Alex Rass a...@itbsllc.com wrote:
  I know this has been raised tons of times, But has anyone ever 
  figured
  out: how to do this and not screw up page versioning?
 
  Any sort of CMS would need this.
 
  I am ok with going to 1.5.M2 for this, btw, if that solves it.
 
  - Alex.
 
 
  
  - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 

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



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




--
Jeremy Thomerson
http://www.wickettraining.com


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



RE: sanity check request for fix regarding the dreaded PageExpiredException

2010-09-27 Thread Alex Rass
Igor's is 100% right

Plus you are forgetting that if you use the default page url constructor -
it goes by interface number which will/may change after a redeploy.
So your lost url bullet can be fixed if you use some url creation strategy
that solidifies in it enough of the path that you can recreate your last
page location 

Then maybe add the important parts of the user state to the same strategy
and you are there.

There are a bunch of examples on how to do this, but I am feeling too lazy
to go search ;) 

- Alex

-Original Message-
From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com] 
Sent: Monday, September 27, 2010 11:28 AM
To: users@wicket.apache.org
Subject: Re: sanity check request for fix regarding the dreaded
PageExpiredException

you can try it and see if it works for your particular usecases. there
may still be some edges that will break, like links you actually want
to run against an older version of the page because they depend on the
component hierarchy that existed then, etc.

-igor

On Fri, Sep 24, 2010 at 7:56 AM, Joe Hudson joe.hud...@clear2pay.com
wrote:
 Hi,

 I know there have been several existing topics around this issue
(http://apache-wicket.1842946.n4.nabble.com/debugging-PageExpiredExceptions-
td1882040.html) for example.  The reason that I am asking for a sanity check
is because I plan to use an alternative approach to solving this issue and
would like feedback to make sure there isn't a reason I shouldn't be doing
this.

 The common approach is to catch the exception and return a new instance of
the requested page.  This seems to have some key drawbacks IMHO:
 1) this only works with bookmarkable links
 2) you lose any modifications to the model that happened after the page
was originally loaded but before the exception occured
 3) any data on the client may potentially be out of sync with the server
state if not updated by the request that caused the exception (because the
new page was loaded but that client representation is still a picture of the
previous page with the previous model).  Although this would be resolved by
a form submit behavior - you would still have problems in the exceptional
cases where the model is updated individually by input field ajax change
events.

 It seems that the page version number is only necessary for a stateless
application and in an ajax-oriented application you would always want to
work with the latest page version.  We seem to hit these issues when
multiple ajax requests that target a particular page happen concurrently
because the page version is incremented when the initial ajax request is
made but all other ajax requests that are initiated before the initial ajax
request response reference a now outdated page version number.

 So, after all that background - do you think this is a valid fix for an
ajax-oriented application:
 Override the default SecondLevelCachePageMap and as long as the requested
page id matches the page id of getLastPage() just return the last page.


 Your thoughts would be appreciated and sorry for the long email but I
wanted to provide background to make sure that the fix was valid for my
particular solution (because I know the fix would not be appropriate for a
stateless application).

 Thanks

 Joe Hudson


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



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



bookmarkablePage strategy change?

2010-09-27 Thread Alex Rass
I have been doing:
webApplication.mountBookmarkablePage(/bob, pageClass);

for quite some time.

And when things got dynamic, it was:
http://site.com/bob?wicket:interface=:0

Did something change in recent releases? Bug? Or did I nuke some important
encoding strategy line some place by accident?

Because now, once things get dynamic, I get:
http://site.com/?wicket:interface=:0
and lose my bob (which helped me keep sanity before).

Can anyone help?

- Alex Rass


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



RE: bookmarkablePage strategy change?

2010-09-27 Thread Alex Rass
Trying to debug my problem where after a form submission on a bookmarked
URL, it loses the mountedPage part and just keeps the ?wicket parameter...
ran into a new problem:
 
Any reason that for build 4.12 source doesn't match the binaries?
Set a breakpoint on  WebRequestCodingStrategy in the encode method
and try to step through - it will not match.

- Alex Rass


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



RE: bookmarkablePage strategy change?

2010-09-27 Thread Alex Rass
Ok, after reading and debugging, seems that bookmarkable page does indeed
drop the source page.
Is there a way to fix that?
So that after I submit the form on that page, I get to keep my bob:
site.com/bob?wickiet=::1::
???
If there's a way to do that, I'd be a happy camper.
Even if it requires going to 1.5M2

- Alex 


-Original Message-
From: Alex Rass [mailto:a...@itbsllc.com] 
Sent: Monday, September 27, 2010 9:23 PM
To: users@wicket.apache.org
Subject: bookmarkablePage strategy change?

I have been doing:
webApplication.mountBookmarkablePage(/bob, pageClass);

for quite some time.

And when things got dynamic, it was:
http://site.com/bob?wicket:interface=:0

Did something change in recent releases? Bug? Or did I nuke some important
encoding strategy line some place by accident?

Because now, once things get dynamic, I get:
http://site.com/?wicket:interface=:0
and lose my bob (which helped me keep sanity before).

Can anyone help?

- Alex Rass


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



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



RE: Best Practice passing data between Bookmarkable pages

2010-08-17 Thread Alex Rass
I may be missing smth simple, but usually to pass data within a session, I
override Session and add whatever holders I need there.
You can add a generic set/getMetaObject one if you want - it's your class.
Wicket should be able to manage the session objects happily.

- Alex 


-Original Message-
From: Martijn Dashorst [mailto:martijn.dasho...@gmail.com] 
Sent: Tuesday, August 17, 2010 9:11 AM
To: users@wicket.apache.org
Subject: Re: Best Practice passing data between Bookmarkable pages

It's a good usecase for metadata. No problem there.

Martijn

On Tue, Aug 17, 2010 at 2:59 PM, Steve Mactaggart
st...@whitesquaresoft.com wrote:
 We do pass params for the actual page's content, but this is transient
 information that I don't want leaking into my URLs.  Its usually a simple
 text message, so I'll look into Session#info(), but I have had some
success
 with my earlier ideas of setMetaData.

 Is there a true purpose for setMetaData? or am I using it a dodgy way?

 I can forsee (fairly soon) a need to render more complex items than just a
 simple string and it seems that (as long as its Serializable) I can put
 anything in MetaData.

 Steve

 On Tue, Aug 17, 2010 at 7:23 PM, Josh Kamau joshnet2...@gmail.com wrote:

 HI Steve;

 When i want to maintain bookmarkable pages, i normally pass the record
 primary key in the PageParameters map . Once i have the primary key on
the
 next page, i can use my dao to retrieve the object and may be float a
div
 to display the record.

 On Tue, Aug 17, 2010 at 10:57 AM, Steve Mactaggart 
 st...@whitesquaresoft.com wrote:

  Hi all,
 
  I have a simple problem that I wanted to cast out to the wider Wicket
  community for a best practice.
 
  We try and use BookmarkablePageLinks for as much as we can, obviously
so
  that pages can be bookmarked.  Therefore nearly every page is
constructed
  via the PageParameters method.
  We have a lot of pages that list items, allow a user to create a new
 item,
  edit, delete, a pretty standard CRUD workflow.
 
  The problem is that I want to notify the user about the the save of the
  save
  on the next page.  If the save fails we stay on the edit page, and that
  works fine.
  But if the save succeeds we redirect back to another page using
  setResponsePage(Class, PageParams).
 
  What I want to do on this page (no matter what page it is) is to
display
 a
  little floating div showing the record just saved, its transaction #
etc.
 
  In the old world I would just push my saved object notification into
the
  Session, and then on all pages check for this value and then display
and
  remove it.
  Is this still the best practice?
 
  I was looking at using something like
  getSession().setMetaData(MetaDataKey, Serializable) to store the the
  notification details, but couldn't see a way to remove the MetaData
 (unless
  setting to null is right)
 
  Is this right or is there a more wicket way of doing this.
 
  Cheers,
  Steve
 





-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com
Apache Wicket 1.4 increases type safety for web applications
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.4.8

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



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



RE: Best Practice passing data between Bookmarkable pages

2010-08-17 Thread Alex Rass
No.
I mean:
You can getSession() to get to the session object.
(I saw you use that so I know you know about it)
But in your Application class, you can create whatever session object you
want as long as it overrides the right class (there's a method for creating
the session you'd override).
Then you add your setters and getters to that session class of yours and use
them when you need to.

- Alex 


-Original Message-
From: jcar...@carmanconsulting.com [mailto:jcar...@carmanconsulting.com] On
Behalf Of James Carman
Sent: Tuesday, August 17, 2010 4:58 PM
To: users@wicket.apache.org
Subject: Re: Best Practice passing data between Bookmarkable pages

You mean metadata on the session?

On Tue, Aug 17, 2010 at 9:11 AM, Martijn Dashorst
martijn.dasho...@gmail.com wrote:
 It's a good usecase for metadata. No problem there.

 Martijn

 On Tue, Aug 17, 2010 at 2:59 PM, Steve Mactaggart 
 st...@whitesquaresoft.com wrote:
 We do pass params for the actual page's content, but this is 
 transient information that I don't want leaking into my URLs.  Its 
 usually a simple text message, so I'll look into Session#info(), but 
 I have had some success with my earlier ideas of setMetaData.

 Is there a true purpose for setMetaData? or am I using it a dodgy way?

 I can forsee (fairly soon) a need to render more complex items than 
 just a simple string and it seems that (as long as its Serializable) 
 I can put anything in MetaData.

 Steve

 On Tue, Aug 17, 2010 at 7:23 PM, Josh Kamau joshnet2...@gmail.com
wrote:

 HI Steve;

 When i want to maintain bookmarkable pages, i normally pass the 
 record primary key in the PageParameters map . Once i have the 
 primary key on the next page, i can use my dao to retrieve the object
and may be float a div
 to display the record.

 On Tue, Aug 17, 2010 at 10:57 AM, Steve Mactaggart  
 st...@whitesquaresoft.com wrote:

  Hi all,
 
  I have a simple problem that I wanted to cast out to the wider 
  Wicket community for a best practice.
 
  We try and use BookmarkablePageLinks for as much as we can, 
  obviously so that pages can be bookmarked.  Therefore nearly every 
  page is constructed via the PageParameters method.
  We have a lot of pages that list items, allow a user to create a 
  new
 item,
  edit, delete, a pretty standard CRUD workflow.
 
  The problem is that I want to notify the user about the the save 
  of the save on the next page.  If the save fails we stay on the 
  edit page, and that works fine.
  But if the save succeeds we redirect back to another page using 
  setResponsePage(Class, PageParams).
 
  What I want to do on this page (no matter what page it is) is to 
  display
 a
  little floating div showing the record just saved, its transaction #
etc.
 
  In the old world I would just push my saved object notification 
  into the Session, and then on all pages check for this value and 
  then display and remove it.
  Is this still the best practice?
 
  I was looking at using something like 
  getSession().setMetaData(MetaDataKey, Serializable) to store the 
  the notification details, but couldn't see a way to remove the 
  MetaData
 (unless
  setting to null is right)
 
  Is this right or is there a more wicket way of doing this.
 
  Cheers,
  Steve
 





 --
 Become a Wicket expert, learn from the best: http://wicketinaction.com 
 Apache Wicket 1.4 increases type safety for web applications Get it 
 now: http://www.apache.org/dyn/closer.cgi/wicket/1.4.8

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



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



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



RE: back link

2010-08-08 Thread Alex Rass
Well, first off, there's a bug:

  setResponsePage( new TargetPage( new SomeModel(),
   OriginatingPage.this );

Needs to be part of constructor call:

  setResponsePage( new TargetPage( new SomeModel(),
   OriginatingPage.this )  );

Second of all: this seems so dirty.
Doing this means that for something THIS simple and common, you need to go
and change ALL your page's constructors?

Yes, I can go through the types of Pages and inherit them all once and add
all features I need into them, but it also seems like it's something that
should be inherent/built in, no?

- Alex

-Original Message-
From: Leszek Gawron [mailto:lgaw...@gmail.com] On Behalf Of Leszek
Gawron
Sent: Friday, 6 August 2010 10:22 PM
To: users@wicket.apache.org
Subject: Re: back link

You are better of with something like this :

public class OriginatingPage extends WebPage {
   public OriginatingPage() {
  add( new Link( targetPage ) {
public void onClick() {
  setResponsePage( new TargetPage( new SomeModel(),
   OriginatingPage.this );
}
  }
   }
}


public class TargetPage extends WebPage {
   public TargetPage( IModel? model, final Page returnPage ) {
 super( model );
 add( new Link( back ) {
   public void onClick() {
 setResponsePage( returnPage );
   }
 }
   }
}


You can use analogous technique for panel replacement.

this way it always 100% predictable (and BTW works when javascript is
not available: javascript turned off, dummy browsers on mobile
devices).

--
Leszek Gawron http://www.mobilebox.pl/krs.html
CTO at MobileBox Ltd.

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


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



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



RE: Tomcat 7 stylesheet problem

2010-08-06 Thread Alex Rass
Try posting that in the Tomcat forums. 7 is still an early beta. Could be
just a bug or a config issue.

- Alex

-Original Message-
From: PDiefent [mailto:pdief...@csc.com] 
Sent: Friday, August 06, 2010 4:57 AM
To: users@wicket.apache.org
Subject: Tomcat 7 stylesheet problem


Hello,
I tried to start my Wicket application with the new Tomcat 7.0.0 release and
got a problem with the stylesheet path:

Source HTML:
?xml version=1.0 encoding=UTF-8?
html xmlns=http://www.w3.org/1999/xhtml;
xmlns:wicket=http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd;
xml:lang=en lang=en
head
meta http-equiv=Content-Type
content=text/html;charset=UTF-8/meta
meta http-equiv=cache-control content=no-cache,no-store/meta
meta http-equiv=pragma content=no-cache,no-store/meta
meta http-equiv=expires content=-1/meta
titleWicketTest/title
link rel=stylesheet type=text/css
href=styles/tabStyles.css/link
/head

body
div wicket:id=tabs class=tabpanel [tab panel]/div
/body
/html

Browser HTML:
?xml version=1.0 encoding=UTF-8?
html xmlns=http://www.w3.org/1999/xhtml;
xmlns:wicket=http://wicket.apache.org/dtds.data/wicket-xhtml1.4-strict.dtd;
xml:lang=en lang=en
head
meta http-equiv=Content-Type
content=text/html;charset=UTF-8/meta
meta http-equiv=cache-control content=no-cache,no-store/meta
meta http-equiv=pragma content=no-cache,no-store/meta
meta http-equiv=expires content=-1/meta
titleWicketTest/title
link rel=stylesheet type=text/css
href=../styles/tabStyles.css/link

The relative Path styles/tabStyles.css is changed to
../styles/tabStyles.css. In Tomcat 5 and 6 relaeses it works fine ...

Any Ideas?
Thanks, Peter
-- 
View this message in context:
http://apache-wicket.1842946.n4.nabble.com/Tomcat-7-stylesheet-problem-tp231
6068p2316068.html
Sent from the Wicket - User mailing list archive at Nabble.com.

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



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



back link

2010-08-06 Thread Alex Rass
Hi.

Here's a cooky-wacky problem:

Added this to my markup:
a href=# onClick=history.go(-1) class=backbuttonBack/a

But when I am running this under the wicket (w/ FFox),  it works great once.
Then it starts jumping me back to this page after I leave it.

Is there something I should be doing differently to create a back button? :)
I know this is an HTML/JS question, but this is a typical thing to do in
HTML and it usually works, afaik.

- Alex


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



wicket super-components

2010-08-04 Thread Alex Rass
Hi.

Are there any resources on finding larger components?

Wicket is SUCH a fantastic architecture for plugin functionality, I am
wondering if there is a place to find components like IMAP Email Access
Components.  Or an FTP Client component etc.

Or would that be Wicket-Stuff? (and if it's not there it's not anywhere?)
http://wicketstuff.org/confluence/display/STUFFWIKI/Wiki

Anyone knows of anything like that?
Yes, I tried google.
Even if it's a list of companies selling their components (a resource is a
resource).

- Alex.


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



RE: tomcat 7.0.0 getRelativePathPrefixToContextRoot

2010-07-19 Thread Alex Rass
Simple solution:
Look at the source for getRelativePathPrefixToContextRoot
And if it's a straight through call to tomcat implementation: post a bug
with tomcat ppl.  
If it's something that wicket does wrong: post a bug here (jira)

Considering Wicket works with Tomcat 5 and 6, I'd guess you'll endup in
tomcat forums.

- Alex 


-Original Message-
From: Ludger Kluitmann [mailto:lkluitm...@googlemail.com] 
Sent: Thursday, July 15, 2010 4:41 AM
To: users@wicket.apache.org
Subject: tomcat 7.0.0 getRelativePathPrefixToContextRoot

Hi,

with running a wicket application under tomcat 7 I found a strange
difference to tomcat 6. getRelativePathPrefixToContextRoot in tomcat 6
is empty. In tomcat 7 getRelativePathPrefixToContextRoot delivers ../

I'm not sure if it is a wicket or a tomcat problem, but nevertheless I
get wrong path settings for some style sheets, javascript and images.

ludger

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



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



RE: Logging

2010-07-19 Thread Alex Rass
Yup :)  Martin's right, this is a bad way of doing it!

You should be getting a logger for your own class. So when the logger does
log - it knows where the errors come from and helps you create proper stack
traces.
You'll also have better control over log levels for different
classes/packages in the future.

private static final Logger log =
LoggerFactory.getLogger(CurrentClassHere.class);

- Alex 

-Original Message-
From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com] 
Sent: Thursday, July 15, 2010 4:15 AM
To: users@wicket.apache.org
Subject: Re: Logging

That's a whole another story ... ;)

**
Martin

2010/7/15 Josh Kamau joshnet2...@gmail.com:
 Thanks Martin. I wanted to make sure am doing the right thing..

 Regards.
 On Thu, Jul 15, 2010 at 10:59 AM, Martin Makundi  
 martin.maku...@koodaripalvelut.com wrote:

        private static final Logger log = 
 LoggerFactory.getLogger(WebPage.class);


 2010/7/15 Josh Kamau joshnet2...@gmail.com:
  Hi guys;
 
  I know wicket comes with pre configured logging . How do i get hold 
  of
 the
  Logger object so that i can log messages in my pages and panels?
 
  regards.
 
  Josh.
 

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




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



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



RE: How to support multiple themes in Wicket application.

2010-06-15 Thread Alex Rass
You guys should check out this site:
http://www.csszengarden.com/

Note the links on the right. Click them - they'll turn same site into a
completely different themes (not even close) by using nothing but CSS.

So if you code your site right for CSS, swapping/adding themes should be a
no-brainer!

- Alex

-Original Message-
From: Chris Colman [mailto:chr...@stepaheadsoftware.com] 
Sent: Tuesday, June 15, 2010 4:56 AM
To: users@wicket.apache.org
Subject: RE: How to support multiple themes in Wicket application.

It depends on whether your themes can be purely defined by styles or whether
some layout changes are also required to support different themes. Often our
themes have required some layout changes in combination with style changes
and so we use markup 'variations' to handle that.

-Original Message-
From: Duy Do [mailto:doquoc...@gmail.com]
Sent: Tuesday, 15 June 2010 2:05 PM
To: users@wicket.apache.org
Subject: How to support multiple themes in Wicket application.

Hi all,

I would like to support multiple themes in Wicket application like 
Wordpress, Drupal. Could you please give me suggestion?

Thanks and regards,
Duy

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



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



is this a bug in ModelT?

2010-06-15 Thread Alex Rass
Hi.

Was writing some code and encountered that 
org.apache.wicket.model.Model T

Always uses direct references to 'object' variable directly. And never as
getObject().
This may hinder overriding methods.

(I found this cause I overwrote getObject() and NOTHING changed :)  
I then looked at the source and knew how to fix it)

Bug or feature?

This is Wicket 1.4.7

- Alex 


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



RE: Creating and zipping binary files for download

2010-06-15 Thread Alex Rass
You should consider that 2 users can be doing it at the same time.
Which will lead to serious errors.
I would suggest using a random file name (or one with session hash in the
filename) so you avoid userA downloading userB's download.zip

I would think that you should be able to just stream it right back to the
client as a redirect or smth. This temporary file thing seems very improper.

- Alex 

-Original Message-
From: Alex Zeit [mailto:zeita...@googlemail.com] 
Sent: Sunday, May 30, 2010 7:30 AM
To: users@wicket.apache.org
Subject: Re: Creating and zipping binary files for download

Thank you very much Jeremy for your help. As you suggested I create
temporary dir and place files there.
Wicket is really great! The solution to my problem was just in couple of
lines of code:

org.apache.wicket.util.file.File wdir = new
org.apache.wicket.util.file.File(createTempDirectory());
ZipResourceStream zrs = new ZipResourceStream(wdir);
ResourceStreamRequestTarget target = new
ResourceStreamRequestTarget(zrs, download.zip);
RequestCycle.get().setRequestTarget(target);


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



RE: is this a bug in ModelT?

2010-06-15 Thread Alex Rass
No, Martin, it can't work.
Look at the implementation.

ALL other methods use object directly.
SO if you just override getObject you'll endup with a broken:
equals(), hashCode(), toString() methods (which breaks any form of caching)
detach() would also be broken.

So no, it can't work.
You HAVE to super.setObject() or setObject() directly and use internal
object to use ModelT class.
Which is not deadly, but a need to know.

Hence: is it a bug or a feature?
Igor? :)

- Alex 


-Original Message-
From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com] 
Sent: Tuesday, June 15, 2010 6:11 AM
To: users@wicket.apache.org
Subject: Re: is this a bug in ModelT?

I did something similar and it works.

**
Martin

2010/6/15 Alex Rass a...@itbsllc.com:
 Hi.

 Was writing some code and encountered that 
 org.apache.wicket.model.Model T

 Always uses direct references to 'object' variable directly. And never 
 as getObject().
 This may hinder overriding methods.

 (I found this cause I overwrote getObject() and NOTHING changed :) I 
 then looked at the source and knew how to fix it)

 Bug or feature?

 This is Wicket 1.4.7

 - Alex


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



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



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



RE: Wicket, IntelliJ and xml resource bundles

2010-05-07 Thread Alex Rass
Tom,

Write to IntelliJ guys to improve support for wicket. Their XML definition
files don't allow a lot of the syntax even in HTML.  They are behind on a
bunch of stuff for wicket. But they are usually good about listening  to end
users. I've had them fix a bunch of stuff in the past. They have forums
which are read by their developers daily!

They gotta try... otherwise it's eclipse for IntelliJ (yak ,yak, yak).

- Alex

-Original Message-
From: Thomas Götz [mailto:t...@richmountain.de] 
Sent: Thursday, May 06, 2010 1:33 PM
To: users@wicket.apache.org
Subject: Re: Wicket, IntelliJ and xml resource bundles

You are right, I just thought there might be a solution for this anyway,
some plugin that I don't know yet maybe (be it Wicket specific or for
general use with IntelliJ/I18N/xml-files).

-Tom


James Carman schrieb:
 Then the stuff you're seeing doesn't have anything to do with Wicket.
 It's IntelliJ's I18N for Java plugin, I believe.  I wouldn't expect 
 it to understand wicket-specific stuff.

 On Thu, May 6, 2010 at 12:26 PM, Thomas Götzt...@richmountain.de  wrote:
 No, I'm not currently using any Wicket plugin.

-Tom


 Nick Heudecker schrieb:
 The Wicket plugin for IDEA doesn't support XML property bundles.

 On Thu, May 6, 2010 at 8:32 AM, James Carman
 jcar...@carmanconsulting.comwrote:

 Are you using a Wicket plugin?

 On Thu, May 6, 2010 at 10:06 AM, Thomas Götzt...@richmountain.de
wrote:
 Any IntelliJ users out there that use Wicket and xml resource 
 bundle
 files?
 I have the problem, that whenever I use something like:

 wicket:message key=foosome text/wicket:message

 in an html file, IntelliJ complains about not being able to 
 resolve the property key. It works when using *.properties 
 resource files, but I
 prefer
 xml. Is there a solution/workaround for this?

-Tom

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



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



RE: Wicket Forms on PS3 Browser

2010-03-13 Thread Alex Rass
Perhaps has to do with:

..., the PS3 browser reports nothing except a user-agent of Mozilla/5.0
(PLAYSTATION 3; 1.00). Everything else is blank. The PS3 apparently does
not send an HTTP-Accept header to the server. It supports Javascript but
will not divulge which version. Finally, it reports no mime types, no
plugins, and no Javascript errors

That and more here:
http://www.design215.com/read.php?title=playstation%203%20browser%20specs

- Alex.


-Original Message-
From: Brad Grier [mailto:brad.gr...@salusnovus.com] 
Sent: Saturday, March 13, 2010 6:24 PM
To: users@wicket.apache.org
Subject: Wicket Forms on PS3 Browser

I just tried out my Wicket-based site on the PS3's native browser. The
strange thing is that none of the forms worked. It's as if the onSubmit is
never called. I went to the Wicket home page and confirmed this behavior. I
don't recall seeing this happen with other forms. I suppose it's not a big
deal but it makes me wonder what's going on.


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



RE: Wicket Forms on PS3 Browser

2010-03-13 Thread Alex Rass
Yeah, but forms that work for other sites don't do all the sweet things that
wicket does for you.
Most sites still have forms that you can double-click. Then spend hours
coding backend to avoid double entry etc.

Someone will fix it... eventually. ;)

Anyone cares to donate a PS3 to Igor? I am sure he'd oblige, right Igor? ;)

Or, at least, record the traffic on the server (wireshark) and post it for
this forum.

- Alex.


-Original Message-
From: Brad Grier [mailto:brad.gr...@salusnovus.com] 
Sent: Saturday, March 13, 2010 8:39 PM
To: users@wicket.apache.org
Subject: Re: Wicket Forms on PS3 Browser

Good link. I didn't really expect the app to work but I thought the form 
submit would be the least of my problems. I still find it interesting that 
forms seem to work for other sites.

--
From: Alex Rass a...@itbsllc.com
Sent: Saturday, March 13, 2010 5:57 PM
To: users@wicket.apache.org
Subject: RE: Wicket Forms on PS3 Browser

 Perhaps has to do with:
 
 ..., the PS3 browser reports nothing except a user-agent of Mozilla/5.0
 (PLAYSTATION 3; 1.00). Everything else is blank. The PS3 apparently does
 not send an HTTP-Accept header to the server. It supports Javascript but
 will not divulge which version. Finally, it reports no mime types, no
 plugins, and no Javascript errors

 That and more here:
 http://www.design215.com/read.php?title=playstation%203%20browser%20specs

 - Alex.


 -Original Message-
 From: Brad Grier [mailto:brad.gr...@salusnovus.com]
 Sent: Saturday, March 13, 2010 6:24 PM
 To: users@wicket.apache.org
 Subject: Wicket Forms on PS3 Browser

 I just tried out my Wicket-based site on the PS3's native browser. The
 strange thing is that none of the forms worked. It's as if the onSubmit is
 never called. I went to the Wicket home page and confirmed this behavior. 
 I
 don't recall seeing this happen with other forms. I suppose it's not a big
 deal but it makes me wonder what's going on.


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

 

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



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



RE: Print friendly panel (pdf)

2010-02-28 Thread Alex Rass
That's what google is doing to print (through a conversion on the back end).
So if you contribute it, I am sure SOMEONE would want it :)

- Alex


-Original Message-
From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com] 
Sent: Sunday, February 28, 2010 12:22 PM
To: users@wicket.apache.org
Subject: Re: Print friendly panel

Hi!

Anybody interested in pdf print script via wicket?

**
Martin

2010/2/28 nino martinez wael nino.martinez.w...@gmail.com:
 Yeah I agree this is the way it should be done. Works like a charm! And
then
 just have a simple js like this:

 script language=Javascript1.2
  !--
  function printpage() {
  window.print();
  }
  //--
 /script

 on or link button or whatever..



 2010/2/28 Riyad Kalla rka...@gmail.com

 This is what I've done in the past as well, allows your user to just
 print
 the page they are staring at and have the browser do the right thing in
 using an alternative style sheet for rendering the page -- this includes
 using a lot of display:none to trim down the parts of the page that you
 don't want printing. This way all you need on your page is a Print link
 that invokes the Print dialog, no other popups ontop of popups.

 Some info:

http://www.scottklarr.com/topic/15/css-create-a-style-sheet-for-print-only/

 

http://www.scottklarr.com/topic/15/css-create-a-style-sheet-for-print-only/
 
 http://webdesign.about.com/cs/css/a/aa042103a.htm

 On Sat, Feb 27, 2010 at 4:54 PM, Alex Rass a...@itbsllc.com wrote:

  Josh,
 
  This doesn't answer your question directly (about a popup).
  But a MUCH simpler way is to make your page printer friendly by
supplying
  an
  alternative CSS for printing format (google on that). Makes life much
  easier.
 
  When you tell your page which css to use, you can say use this CSS for
  printing only. All transparent to the user.
 
  - Alex
 
 
  -Original Message-
  From: Josh Chappelle [mailto:jchappe...@4redi.com]
  Sent: Friday, February 26, 2010 4:09 PM
  To: users@wicket.apache.org
  Subject: Print friendly panel
 
  Hi,
 
 
 
  Does anyone know of a suggested method to render a printer friendly
panel
  to
  a separate browser window so that user's can print? The only thing I
have
  found is the following article and it looks a little clunky.
 
 
 
  http://cwiki.apache.org/WICKET/rendering-panel-to-a-string.html
 
 
 
  Basically I just need to be able to place a link that when clicked will
 pop
  up a new browser window with only the contents to the target panel.
That
  way
  users can print that panel from there.
 
 
 
  Thanks,
 
 
 
  Josh
 
 
 
 
 
 
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 



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



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



RE: Print friendly panel

2010-02-27 Thread Alex Rass
Josh, 

This doesn't answer your question directly (about a popup).
But a MUCH simpler way is to make your page printer friendly by supplying an
alternative CSS for printing format (google on that). Makes life much
easier.

When you tell your page which css to use, you can say use this CSS for
printing only. All transparent to the user.

- Alex


-Original Message-
From: Josh Chappelle [mailto:jchappe...@4redi.com] 
Sent: Friday, February 26, 2010 4:09 PM
To: users@wicket.apache.org
Subject: Print friendly panel

Hi,

 

Does anyone know of a suggested method to render a printer friendly panel to
a separate browser window so that user's can print? The only thing I have
found is the following article and it looks a little clunky.

 

http://cwiki.apache.org/WICKET/rendering-panel-to-a-string.html

 

Basically I just need to be able to place a link that when clicked will pop
up a new browser window with only the contents to the target panel. That way
users can print that panel from there.

 

Thanks,

 

Josh

 

 



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



RE: better look modern css for wicket

2010-02-01 Thread Alex Rass
I suspect they don't do it b/c ... it's a job for a designer!
I think it's pretty damn good already. And there are already 3 looks for
some component (look at the CSS file).

And while it wouldn't bring more people to wicket (that's not why ppl go
wicket, that's silly), it would make for more support costs when the guys
change components or add new ones (having to update ALL those looks and
feels).

It's just a CSS file. (thank god!)

If you think it will help you and others: Just create a project and start
dumping your super-duper-pretty CSS files inthere along with a test page
which displays the basic 10+ components wicket supports out of the box and
show off how they look. There are a BUNCH of nice CSS development sites
where you have a dropdown which switches between CSS files for same content.
Do something like that.

- Alex

-Original Message-
From: Riyad Kalla [mailto:rka...@gmail.com] 
Sent: Monday, February 01, 2010 11:19 AM
To: users@wicket.apache.org
Subject: Re: better look  modern css for wicket

Shipping a few different custom themes as part of the Wicket SDK could be
interesting -- for the standard Wicket components that just back HTML4
elements it's a little less necessary I suppose, but for those custom
components, like Data Tables, making them look nice out of the box could be
a nice win. I suppose the same goes for some standard HTML widgets
(buttons?)

I wonder if there could be a Wicket 1.6 addition of a ThemeManager that all
wicket components could call into for default styles -- including the
custom components -- allowing artists to define well-known style names that
would get applied automatically and allow Wicket to ship themes out of the
box with it?

e.g. in Application.init() -- ThemeManager.setDefault(green-gloss.css)

As superficial as it is, we all know bling counts. If there is a huge demand
for making Wicket components look like an 1990s AOL webpage, I'll take the
lead on this... otherwise we should probably ask if anyone is a designer? :)

On Mon, Feb 1, 2010 at 9:04 AM, Jing Ge (Besitec IT DEHAM)
j...@besitec.comwrote:

 Hi guys,

 I just ask myself, why the wicket team does not provide a better look,
 more modern css? A css which will let people say WOW! when they open
 the wicket demo page, like Vaadin does.

 Such a css can let more people pay attention to wicket. Why don't do it?


 BTW, The wicket is really cool! I like it!

 Regards
 Jing


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



Caching: Expires HTTP header and ETags

2009-12-21 Thread Alex Rass
Hi.

Ran into a bunch of places saying we need to have the Expires header set for
images and other static content. (To enable browser caching to work
properly).

1) Anything is done to do this automatically? Any plans to?

2) If I go ahead and use some filter to do this myself, is there any harm in
setting it for the wicket's js files?
/resources/org.apache.wicket.ajax.WicketAjaxReference/wicket-ajax.js;jsessio
nid=numeric_id_here


For background:
This link has a how-to on how to do it via a filter:
http://www.infoq.com/articles/gwt-high-ajax 

3) Does wicket have ETag support?

Thanks,
- Alex Rass


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



RE: Location of css and js files

2009-12-20 Thread Alex Rass
Global resources you can reference globally. Use can use the non-wicket
links. Container hosts folders you can use.

Idea behind this is to use components which are fully contained. Hence (all
in one place).  If this doesn't suit you - there are bunch of tutorials on
how to load resources from elsewhere.

- Alex


-Original Message-
From: Dale Ogilvie [mailto:dale.ogil...@trimble.co.nz] 
Sent: Sunday, December 20, 2009 10:41 PM
To: users@wicket.apache.org
Subject: RE: Location of css and js files


Thanks Igor.

So having your css and js collected off under another path is not the
wicket way?

Are you saying the following for best-practice:

com/acme/myweb
 HelloWorldPage.java
 HelloWorldPage.html
 style.css
 Javascript.js

What about images used by the css? Would these live alongside the
style.css as well?


-Original Message-
From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com] 
Sent: Monday, 21 December 2009 4:23 p.m.
To: users@wicket.apache.org
Subject: Re: Location of css and js files

head
wicket:link
link rel='stylesheet' href='style.css' type='text/css' script
type=text/javascript src=javascript.js/script /wicket:link
/head

and have the files in the same package as the page

-igor

On Sun, Dec 20, 2009 at 7:21 PM, Dale Ogilvie
dale.ogil...@trimble.co.nz wrote:

 Hello,

 For html page markup containing style and javascript, what is the best

 practice for positioning the css and js files, so that they are 
 available both at design time, and at run time?

 I want the designer to be able to see the markup in full glory, while 
 still having this translate properly at run-time.

 I'm thinking of an html file such as:

 html
 head
 link rel='stylesheet' href='style.css' type='text/css' script 
 type=text/javascript src=javascript.js/script /head body p

 class=pretty onclick=doit();Hello world/p /body /html

 If this markup is alongside the java source, that would imply that the

 css and js would also have to be there. But tradition would have these

 files under a sub directory like so:

 ...
 link rel='stylesheet' href='/style/style.css' type='text/css' 
 script type=text/javascript src=/js/javascript.js/script ...

 What is the wicket way?

 Thanks!

 Dale

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



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


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



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



RE: Pretty URLs and sessions

2009-12-17 Thread Alex Rass
V,

What you are looking for can be addressed in 2 ways.

GA gives you a value to add to the page's html: some javascript which calls
home and reports URL it was called from.
This will tell you which items customers are looking at: item_id=2098

Using HybridUrlCodingStrategy (as per Alex O) will let GA see the
item_id=2098 or however you choose to encode urls (there are multiple
strategies).  If you tracked id of the item internally - wouldn't show up in
URL in a consistent way.

You ALSO could forget the GA and track this stuff far better in your own
code. Cause then you could track 2000 other things that GA can't.  Like if
customer comes back a day later. It's not new interest.  But with a login
- you'll know more than GA possibly can.

- Alex.


-Original Message-
From: VGJ [mailto:zambi...@gmail.com] 
Sent: Thursday, December 17, 2009 1:30 PM
To: users@wicket.apache.org
Subject: Re: Pretty URLs and sessions

Thanks Alex.

I just had another meeting w/ the SEO guy today and the idea is to track
orders moving through our storefront in order go gauge sales based on the
SEO strategy.  In other words, where did our customers come from (Google
search?), what did they buy, and did they make it all the way through the
checkout process.  We need to be able to track pages in Google Analytics.

If we could append/prepend some sort of value to the pages, while keeping
the dynamic Wicket page version parameter info in there, it would be
sufficient.  In Analytics, the Wicket portion of the URL can be removed and
the rest would be used to identify traffic moving through the site.

Is HybridUrlCodingStrategy the way to go, with this in mind?  Where are some
good examples as to how to implement it and do what I'm describing?

Thanks again!

-v

On Tue, Dec 1, 2009 at 6:04 AM, Alex Objelean
alex_objel...@yahoo.comwrote:


 You can mount your page with HybridUrlCodingStrategy. This way, even
 session
 relative url's will be SEO friendly.

 But you must be aware of one thing, it makes sense to make SEO only
 bookmarkable pages (stateless pages). It is meaningless to make SEO aware
 session relative pages, because these will be shown as expired when
 somebody
 else will use these links.

 Regards,
 Alex Objelean


 V. Jenks wrote:
 
  I'm working on some changes for our storefront (Wicket 1.4, Java EE 5,
  Glassfish 2.1) based on some recommendations made to us by an SEO
  consultant.  One of them is re-writing some of the URLs so as to have
 them
  indexed by Google, etc.
 
  My concern is the Wicket WebSession that I use to pass around an
instance
  of
  a stateful session bean.  If I redirect to a mounted bookmarkable page
  when
  going through pages in the checkout process, vs redirecting to a new
  instances of the page class, will there be any adverse effects on the
  session?  Will customers experience a problem with their shopping cart
  sessions?
 
  Thanks!
 
 

 --
 View this message in context:

http://old.nabble.com/%22Pretty%22-URLs-and-sessions-tp26581608p26591380.htm
l
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




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



RE: Pretty URLs and sessions

2009-12-17 Thread Alex Rass
 They're so wowed by GA, I doubt there's any turning back.

Explain to your guys that GA is Google.
If he is ok with Google knowing as much (or more) than you guys do about
your own sales - then party on! Go GA!

Also, you can track a lot more stuff than GA will let you since you know/own
everything that goes on. Everything they clicked, how long they spent where,
you can even track where their mouse was hovering! ;)

- Alex R.

-Original Message-
From: VGJ [mailto:zambi...@gmail.com] 
Sent: Thursday, December 17, 2009 4:08 PM
To: users@wicket.apache.org
Subject: Re: Pretty URLs and sessions

Excellent, excellent!  This is exactly what I was after!  That is...unless
this SEO can find another monkey wrench to throw in it.  But...it looks like
it's exactly what I need.  Thanks!

Alex R. - good point on tracking info internally.  I think it'd be very
useful but I'm dealing w/ the marketing dept.  They're so wowed by GA, I
doubt there's any turning back.

Thanks guys.

On Thu, Dec 17, 2009 at 12:08 PM, Alex Objelean
alex_objel...@yahoo.comwrote:


 There are two possibilities:
 1) In your application class add the following:
 mount(new HybridUrlCodingStrategy(/checkout, CheckoutPage.class));

 2) If you have wicket-stuff annotation dependency
 (
 http://wicketstuff.org/confluence/display/STUFFWIKI/wicketstuff-annotation
 )
 you can annotate your page class with:

 @MountPath(path=/checkout)
 @MountHybrid
 public class CheckoutPage extends WebPage {}

 Alex



 V. Jenks wrote:
 
  Thanks Alex.
 
  I just had another meeting w/ the SEO guy today and the idea is to track
  orders moving through our storefront in order go gauge sales based on
the
  SEO strategy.  In other words, where did our customers come from (Google
  search?), what did they buy, and did they make it all the way through
the
  checkout process.  We need to be able to track pages in Google
Analytics.
 
  If we could append/prepend some sort of value to the pages, while
keeping
  the dynamic Wicket page version parameter info in there, it would be
  sufficient.  In Analytics, the Wicket portion of the URL can be removed
  and
  the rest would be used to identify traffic moving through the site.
 
  Is HybridUrlCodingStrategy the way to go, with this in mind?  Where are
  some
  good examples as to how to implement it and do what I'm describing?
 
  Thanks again!
 
  -v
 
  On Tue, Dec 1, 2009 at 6:04 AM, Alex Objelean
  alex_objel...@yahoo.comwrote:
 
 
  You can mount your page with HybridUrlCodingStrategy. This way, even
  session
  relative url's will be SEO friendly.
 
  But you must be aware of one thing, it makes sense to make SEO only
  bookmarkable pages (stateless pages). It is meaningless to make SEO
 aware
  session relative pages, because these will be shown as expired when
  somebody
  else will use these links.
 
  Regards,
  Alex Objelean
 
 
  V. Jenks wrote:
  
   I'm working on some changes for our storefront (Wicket 1.4, Java EE
5,
   Glassfish 2.1) based on some recommendations made to us by an SEO
   consultant.  One of them is re-writing some of the URLs so as to have
  them
   indexed by Google, etc.
  
   My concern is the Wicket WebSession that I use to pass around an
  instance
   of
   a stateful session bean.  If I redirect to a mounted bookmarkable
page
   when
   going through pages in the checkout process, vs redirecting to a new
   instances of the page class, will there be any adverse effects on the
   session?  Will customers experience a problem with their shopping
cart
   sessions?
  
   Thanks!
  
  
 
  --
  View this message in context:
 

http://old.nabble.com/%22Pretty%22-URLs-and-sessions-tp26581608p26591380.htm
l
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 
 

 --
 View this message in context:

http://old.nabble.com/%22Pretty%22-URLs-and-sessions-tp26581608p26833349.htm
l
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




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



RE: Redirect after for submit, but not what you think

2009-12-08 Thread Alex Rass
So: always override onSumbit for the buttons and *sometimes* redirect.
Tis all.

- Alex

-Original Message-
From: Robert Moskal [mailto:rmos...@mostmedia.com] 
Sent: Tuesday, December 08, 2009 12:05 PM
To: users@wicket.apache.org
Subject: Redirect after for submit, but not what you think

Hi all:

I'd like to be able to redirect after I submit a form, basically I want my
app to navigate to the next question in a survey after a user responds.  But
I don't want to do this in the onClick method of the form buttons, because I
only want to do this sometimes.  In other words sometimes I want to deploy
an application where I do the auto-navigation and sometimes I want the user
to stay on the same page after submitting.

The ideal place seems to be on the page level.  but it seems you can't call
setResponsePage in the onDetach method.  Where in request life-cycle would
be the place to do this sort of redirect?

Thanks and regards,
___
Robert Moskal
Most Media
Brooklyn, USA
347-529-4744


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



RE: making tinyMce TextArea readonly

2009-12-02 Thread Alex Rass
Yeah, would be good to update the whole tinyMCE thing.
It's SO popular!
It's rather outdated from what's on tinyMCE site.
It should really be repackaged with some helper stuff like 
setReadOnly(true/false).
And provide with a convenient tabbed panel for HTML/RAW edit window.

Anyone who knows how to wants to help?


-Original Message-
From: tubin gen [mailto:fachh...@gmail.com] 
Sent: Wednesday, December 02, 2009 11:34 AM
To: users
Subject: making tinyMce TextArea readonly

I ma trying to make TextArea with TinyMce behaviour readonly  , I added
the following custom settings but it did not work
tinyMCESettings.addCustomSetting(readonly : true);
tinyMCESettings.addCustomSetting(mode : textareas);

please suggest me   how to make  it readonly ?


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



RE: How to render raw HTML

2009-12-01 Thread Alex Rass
There was this little class somewhere in help.
Obviously needs a little change for getting actual content and piping it
out, but from here - it's not far.
Hope this helps.


/**
 * Use if you want to redirect entire page and dump this one.
 */
static class ImportTag extends WebMarkupContainer {
private static final long serialVersionUID = 1L;

ImportTag(String id) {
super(id);
}

@Override
protected void onRender(MarkupStream markupStream) {
markupStream.next();
try {
WebRequestCycle cycle = (WebRequestCycle)
RequestCycle.get();
ServletRequest request =
cycle.getWebRequest().getHttpServletRequest();
ServletResponse response =
cycle.getWebResponse().getHttpServletResponse();
ServletContext context = ((WebApplication)
Application.get()).getServletContext();
context.getRequestDispatcher(/ + getId() +
.html).include(request, response);
}
catch (Exception e) {
throw new WicketRuntimeException(e);
}
}
} // class ImportTag


-Original Message-
From: Alec Swan [mailto:alecs...@gmail.com] 
Sent: Tuesday, December 01, 2009 5:55 PM
To: users@wicket.apache.org
Subject: How to render raw HTML

I am using Wicket 1.4.2 and would like to be able to render raw HTML pages
which are stored in an existing database. I saw that other people attempted
doing
thishttp://markmail.org/message/sleaiygl3buwgqcn#query:AutoComponentPanel+p
age:1+mid:sleaiygl3buwgqcn+state:resultsand
am wondering if there is a way to do this without creating a lot of
custom code?

Thanks,

Alec


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



RE: Posting A Form To NonWicket

2009-11-21 Thread Alex Rass
 I'm concerned about the security since anyone could view source and  see
the action url and try to post the form. Please let me know if any other
alternative. Thanks.

Well, if you do it on backend (through code) - no one knows what's going on
- they are just submitting a form to YOUR server.

Not sure what BIRT is. Hope it's not important.
Well, timeline looks like this:
Client hits Submit on WicketForm1
WicketForm1.onSumbit() is launched (or action you associated with the
WicketForm1.formbutton).
In onSumbit, you take all your values, and you take apache-http-commons and
you use it to POST data to your TargetServer's form. Then read the reply
(it's a 1-shot deal. You post - it replies back with a page), parse it up,
extract whatever stuff you need (hope it d/n change often on you).
Then you can populate a WicketForm1.label or something with results from
what you parsed out (you can tell label to not change html). And screen is
returned to a Client with results.  You can also redirect to appropriate
page instead (bunch of redirect options available in wicket)

Hope this helps.

-Original Message-
From: chocba [mailto:cho...@gmail.com] 
Sent: Saturday, November 21, 2009 11:16 AM
To: users@wicket.apache.org
Subject: RE: Posting A Form To NonWicket


Basically, my form will post to an action url pointing to BIRT viewer, a web
appplication of BIRT. If I use httpcommons, how will I get the web content
in to the same window from where I'm posting the form. Please let me know.
Thanks for the response.


Alex Rass wrote:
 
 You could write something on the server end (or your wicket app) that
 would
 do it for you.
 Just use apache http commons or write your own post code. Easy stuff (open
 socket, couple commands, dump input, close socket).
 
 It can even get back to the user with error codes from the other server
 etc
 if you wanna be spiffy.
 
 
 -Original Message-
 From: Balaji C [mailto:cho...@gmail.com] 
 Sent: Friday, November 20, 2009 12:15 PM
 To: users@wicket.apache.org
 Subject: Posting A Form To NonWicket
 
 I've a wicket form with input elements. I would like to post this form to
 a
 non-wicket url. Is it possible to post this form from submit event of
 wicket
 button? I google and couldn't find any clear solution. Any help is
 appreciated. If any other alternative, please let me know. Thanks.
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 

-- 
View this message in context:
http://old.nabble.com/Posting-A-Form-To-NonWicket-tp26447615p26457990.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



RE: Posting A Form To NonWicket

2009-11-20 Thread Alex Rass
You could write something on the server end (or your wicket app) that would
do it for you.
Just use apache http commons or write your own post code. Easy stuff (open
socket, couple commands, dump input, close socket).

It can even get back to the user with error codes from the other server etc
if you wanna be spiffy.


-Original Message-
From: Balaji C [mailto:cho...@gmail.com] 
Sent: Friday, November 20, 2009 12:15 PM
To: users@wicket.apache.org
Subject: Posting A Form To NonWicket

I've a wicket form with input elements. I would like to post this form to a
non-wicket url. Is it possible to post this form from submit event of wicket
button? I google and couldn't find any clear solution. Any help is
appreciated. If any other alternative, please let me know. Thanks.


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



RE: Intellij9 integration

2009-11-15 Thread Alex Rass
Would be good if it told you about unmentioned wicket:ids from the html so
you didn't have to wait till you run.
Or if you are declaring a component that it can't find in html.

Jumping back and forth between code and html d/n seem to work for me.

Entirely too much typing for my taste! Idea is REALLY good at minimizing on
that.

Bunch of templates can be written for Wicket programmers to simplify typical
stuff.

But yes, a lot of things in IJ work already because wicket isn't a stretch
for java.


-Original Message-
From: Peter Ertl [mailto:pe...@gmx.org] 
Sent: Sunday, November 15, 2009 10:08 AM
To: users@wicket.apache.org
Subject: Re: Intellij9 integration

Never felt like I need additional support for wicket. After all it's 95% in
type-safe java code. Keeping wicket:id's in sync is no rocket science once
you get the idea :-)

Am 15.11.2009 um 00:38 schrieb Nick Heudecker:

 What do you mean that the current one shows up?  I haven't updated
 WicketForge to work with IDEA 9 because I'm not on IDEA 9.
 
 Feel free to submit patches.  Right now WicketForge does everything I need
 it to do, so unless I start using Wicket more often or it doesn't meet my
 needs, I'm not really inclined to spend my limited free time on it.
 
 On Sat, Nov 14, 2009 at 3:12 PM, Alex Rass a...@itbsllc.com wrote:
 
 You have a point, but I've been using Idea for... 6+ years now.
 These guys are very sales oriented.
 They added GWT support as a point release, like it was a no big deal.
 When they see there's a demand - they move on it.
 And if they can add a new popular framework for the launch - they just
may,
 to make it sell better. They are in a war with Eclipse and we got that
and
 it's better has been their selling angle.
 
 But if someone wants to make the wicketidea plugin actually work - that'd
 be
 cool too :)  Current one barely shows up and is VERY sensitive.
 
 
 -Original Message-
 From: Andreas Petersson [mailto:andr...@petersson.at]
 Sent: Saturday, November 14, 2009 5:00 PM
 To: users@wicket.apache.org
 Subject: Re: Intellij9 integration
 
 i think getting official support for wicket in idea is too late. the
 roadmap was published about 6 months ago, for example at
 http://blogs.jetbrains.com/idea/2009/05/maia-eap-is-finally-here/
 and there is already a beta version available at
 http://www.jetbrains.com/idea/nextversion/index.html
 
 but maybe it is the right time to give wicketforge some polish. my
 suggestions for enhancements, since it should be possible to better
 develop plugins since it is open source now.
 *) validation of propertymodels/CPM like idea does for expression
 Language for jsp. ability to ctrl-click to the corresponding getter and
 find usages of those getters
 *) support for find usages for wicket:ids
 *) central facet for wicket, to control its settings.
 *) ability to turn off the non-serializable field in serializable
 class warning in components for fields that are injected.
 
 br
 andreas
 
 


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



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



RE: Intellij9 integration

2009-11-15 Thread Alex Rass
Nick, biggest problem was RTFM.
Most plugins in IJ don't need to be activated.

I didn't realize that there were more steps than install plugin :)
Any chance you can just auto-add the Wicket module?
If it's heavy, then at least add the comment to the plugin description
like: 
WicketForge assists developers creating Wicket applications.

To activate for a given project, add to modules. See
http://code.google.com/p/wicketforge/wiki/UsageInstructions for details on
how to do so.

This plugin...


I added the module, now I can jump b/w the declarations etc.
The html editor still complains about wicket:id tags, of course. Which makes
the 20 fake errors in html errors cover up the REAL error of non-matching
wicket:id to code.  But I am sure you know about that already.

Would love to help you with patches, but I know NOTHING about IJ plugin
development :( 

Drop a line in the forum when you release, please!


-Original Message-
From: Nick Heudecker [mailto:nheudec...@gmail.com] 
Sent: Sunday, November 15, 2009 5:57 PM
To: users@wicket.apache.org
Subject: Re: Intellij9 integration

From my experience, WicketForge already displays a warning if the components
can't be located in the HTML or Java code.  Toggling between Java and HTML
also works fine for me.  You can either submit a bug report or a patch.

Also, feel free to submit a patch with templates you'd like to see added to
WF.  I'm getting ready to release 0.5.7 this week.

On Sun, Nov 15, 2009 at 11:49 AM, Alex Rass a...@itbsllc.com wrote:

 Would be good if it told you about unmentioned wicket:ids from the html
 so
 you didn't have to wait till you run.
 Or if you are declaring a component that it can't find in html.

 Jumping back and forth between code and html d/n seem to work for me.

 Entirely too much typing for my taste! Idea is REALLY good at minimizing
on
 that.

 Bunch of templates can be written for Wicket programmers to simplify
 typical
 stuff.

 But yes, a lot of things in IJ work already because wicket isn't a stretch
 for java.


 -Original Message-
 From: Peter Ertl [mailto:pe...@gmx.org]
 Sent: Sunday, November 15, 2009 10:08 AM
 To: users@wicket.apache.org
 Subject: Re: Intellij9 integration

 Never felt like I need additional support for wicket. After all it's 95%
in
 type-safe java code. Keeping wicket:id's in sync is no rocket science once
 you get the idea :-)

 Am 15.11.2009 um 00:38 schrieb Nick Heudecker:

  What do you mean that the current one shows up?  I haven't updated
  WicketForge to work with IDEA 9 because I'm not on IDEA 9.
 
  Feel free to submit patches.  Right now WicketForge does everything I
 need
  it to do, so unless I start using Wicket more often or it doesn't meet
my
  needs, I'm not really inclined to spend my limited free time on it.
 
  On Sat, Nov 14, 2009 at 3:12 PM, Alex Rass a...@itbsllc.com wrote:
 
  You have a point, but I've been using Idea for... 6+ years now.
  These guys are very sales oriented.
  They added GWT support as a point release, like it was a no big deal.
  When they see there's a demand - they move on it.
  And if they can add a new popular framework for the launch - they just
 may,
  to make it sell better. They are in a war with Eclipse and we got that
 and
  it's better has been their selling angle.
 
  But if someone wants to make the wicketidea plugin actually work -
 that'd
  be
  cool too :)  Current one barely shows up and is VERY sensitive.
 
 
  -Original Message-
  From: Andreas Petersson [mailto:andr...@petersson.at]
  Sent: Saturday, November 14, 2009 5:00 PM
  To: users@wicket.apache.org
  Subject: Re: Intellij9 integration
 
  i think getting official support for wicket in idea is too late. the
  roadmap was published about 6 months ago, for example at
  http://blogs.jetbrains.com/idea/2009/05/maia-eap-is-finally-here/
  and there is already a beta version available at
  http://www.jetbrains.com/idea/nextversion/index.html
 
  but maybe it is the right time to give wicketforge some polish. my
  suggestions for enhancements, since it should be possible to better
  develop plugins since it is open source now.
  *) validation of propertymodels/CPM like idea does for expression
  Language for jsp. ability to ctrl-click to the corresponding getter and
  find usages of those getters
  *) support for find usages for wicket:ids
  *) central facet for wicket, to control its settings.
  *) ability to turn off the non-serializable field in serializable
  class warning in components for fields that are injected.
 
  br
  andreas
 
 




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



RE: CompoundPropertyModel

2009-11-14 Thread Alex Rass
Kolya,

2 things:
1) If you still have the old setup:
  Try stopping server, deploying your stuff to it, starting server.
  I've had issues with redeploying at runtime (hot deploy) with Tomcat
(which is what Glassfish is based on).  This is where Jeremy's advice to run
Jetty is a good idea.

2) Make sure that you refresh the form in your web browser before you try to
enter data and submit.  Wicket needs to do stuff to that form before you can
submit it and if you keep same browser open between deployments, you are
sending data back to wicket that it knows nothing about, so it blows up with
pageexpired.

The fact that you don't get serialization errors in the log (if it wasn't
serialized) is b/c it didn't get that far yet, so problems are elsewhere.

Hope this helps,
- Alex. 

-Original Message-
From: Николай Кучумов [mailto:kuchum...@gmail.com] 
Sent: Saturday, November 14, 2009 9:33 AM
To: users@wicket.apache.org
Subject: Re: CompoundPropertyModel

Hi, Jeremy.
No, the log contained only this error...
But to be honest, although it didn't fix the error, your advice is still
valuable, because not all of the classes were Serializable.
And you know what?
I think I'll reinstall my application server.
I used Glassfish 2 before, and this time I tried Glassfish 3, but it
appeared to be a bitch...
It hangs oftenly and operates strangely...
So maybe it somehow messes with the sessions...
I'll install Glassfish 2 back then, when I have more time for this (maybe
tomorrow), and then I'll post the results here.
Thanks for your reply.

On Sat, Nov 14, 2009 at 5:11 PM, Jeremy Thomerson jer...@wickettraining.com
 wrote:

 Do both Person and Credentials (and everything else Person holds on to)
 implement Serializable?

 Watch the logs to see if there are serialization errors.  It's a problem
of
 the page not being in the session - which means it either didn't make it
 there or the session is somehow gone.

 --
 Jeremy Thomerson
 http://www.wickettraining.com



 On Sat, Nov 14, 2009 at 7:26 AM, Николай Кучумов kuchum...@gmail.com
 wrote:

  Hello.
  I have a Person class, describing a person, which has a member
  credentials of type Credentials (username/password).
  I tried to make a registration page in this way:
 
  Page
  {
 super();
 
 Person person = [create a person with empty credentials];
 
 Form form = new Form(form, new CompoundPropertyModel(person));
 
 add(form);
 
 form.add(new TextField(familyName));
 form.add(new TextField(givenName));
 
 form.add(new TextField(credentials.userName));
 form.add(new TextField(credentials.passWord));
 
 // also add a submit button
  }
 
  And now when I push the Submit button, it outputs this error:
 
  org.apache.wicket.protocol.http.PageExpiredException: Cannot find the
  rendered page in session [pagemap=null,componentPath=0,versionNumber=0]
 
  I like the idea of compound object model, and I wouldn't like to deprive
  myself from using it just because of this strange error...
  Can you give me a hint on what have I done wrong in the code above?
 



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



Intellij9 integration

2009-11-14 Thread Alex Rass
If any of you guys are using Intellij Idea, I HIGHLY suggest you go to the 
EAP Forum http://intellij.net/forums/forum.jspa?forumID=22 
and post that you want Wicket support in 9.

They have opened up EAP for version 9 and it's now or god knows when.

They are starting an Open Source version this time. And their product is
100x better than Eclipse.

Lets get them to integrate wicket in, so it gets popularity and recognition
it deserves.



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



RE: Intellij9 integration

2009-11-14 Thread Alex Rass
You have a point, but I've been using Idea for... 6+ years now.
These guys are very sales oriented.
They added GWT support as a point release, like it was a no big deal.
When they see there's a demand - they move on it. 
And if they can add a new popular framework for the launch - they just may,
to make it sell better. They are in a war with Eclipse and we got that and
it's better has been their selling angle.

But if someone wants to make the wicketidea plugin actually work - that'd be
cool too :)  Current one barely shows up and is VERY sensitive.


-Original Message-
From: Andreas Petersson [mailto:andr...@petersson.at] 
Sent: Saturday, November 14, 2009 5:00 PM
To: users@wicket.apache.org
Subject: Re: Intellij9 integration

i think getting official support for wicket in idea is too late. the 
roadmap was published about 6 months ago, for example at
http://blogs.jetbrains.com/idea/2009/05/maia-eap-is-finally-here/
 and there is already a beta version available at
http://www.jetbrains.com/idea/nextversion/index.html

but maybe it is the right time to give wicketforge some polish. my 
suggestions for enhancements, since it should be possible to better 
develop plugins since it is open source now.
*) validation of propertymodels/CPM like idea does for expression 
Language for jsp. ability to ctrl-click to the corresponding getter and 
find usages of those getters
*) support for find usages for wicket:ids
*) central facet for wicket, to control its settings.
*) ability to turn off the non-serializable field in serializable 
class warning in components for fields that are injected.

br
andreas

 If any of you guys are using Intellij Idea, I HIGHLY suggest you go to the

 EAP Forum http://intellij.net/forums/forum.jspa?forumID=22 
 and post that you want Wicket support in 9.
   


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



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



RE: Error on Websphere 6.1 for Wicket Application

2009-11-13 Thread Alex Rass
It's not a problem. It's a warning.
Just means that it's not optimized for production and you will see an ajax
debug message in the UI.
Everything will run perfectly fine.

It's a setting to turn production mode on and off.
By the time you write ANYTHING, you would have figured out how to turn it
on/off ;)

Usually you can do it through a setting in web.ini

Google: wicket setting development production

- Alex.


-Original Message-
From: vinay.karmar...@wipro.com [mailto:vinay.karmar...@wipro.com] 
Sent: Friday, November 13, 2009 1:26 AM
To: users@wicket.apache.org
Subject: Error on Websphere 6.1 for Wicket Application

Hi,

 

I am using Websphere 6.1 as App Server  Rational Application Developer
environment for development of Wicket Application.

I am getting the following error while trying to access the application.

 

[11/12/09 10:34:24:033 IST] 0031 SystemErr R


*** WARNING: Wicket is running in DEVELOPMENT mode.  ***

***   ^^^***

*** Do NOT deploy to your live server(s) without changing this.  ***

*** See Application#getConfigurationType() for more information. ***



[11/12/09 10:34:24:065 IST] 0031 ServiceLogger I
com.ibm.ws.ffdc.IncidentStreamImpl initialize FFDC0009I: FFDC opened
incident stream file C:\Program
Files\IBM\SDP70\runtimes\base_v61\profiles\AppSrv09\logs\ffdc\server1_1b
381b38_09.11.12_10.34.24_0.txt

[11/12/09 10:34:24:393 IST] 0031 ServiceLogger I
com.ibm.ws.ffdc.IncidentStreamImpl resetIncidentStream FFDC0010I: FFDC
closed incident stream file C:\Program
Files\IBM\SDP70\runtimes\base_v61\profiles\AppSrv09\logs\ffdc\server1_1b
381b38_09.11.12_10.34.24_0.txt

[11/12/09 10:34:24:424 IST] 0031 SRTServletRes W   WARNING: Cannot
set status. Response already committed.

[11/12/09 10:34:24:487 IST] 0031 SRTServletRes W   WARNING: Cannot
set header. Response already committed.

 

Can anyone suggest any solution for this problem?

 

 

Regards,

 

Vinay Karmarkar


Please do not print this email unless it is absolutely necessary. 

The information contained in this electronic message and any attachments to
this message are intended for the exclusive use of the addressee(s) and may
contain proprietary, confidential or privileged information. If you are not
the intended recipient, you should not disseminate, distribute or copy this
e-mail. Please notify the sender immediately and destroy all copies of this
message and any attachments. 

WARNING: Computer viruses can be transmitted via email. The recipient should
check this email and any attachments for the presence of viruses. The
company accepts no liability for any damage caused by any virus transmitted
by this email. 

www.wipro.com


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



RE: page without class

2009-11-13 Thread Alex Rass
Yup. Works for me!

Or just configure tomcat or whatever you use as servlet container to pick up
the files elsewhere. This has totally nothing to do with Wicket.
It, very wisely, picks up just the stuff it knows about. All your other
requests fall through to Tomcat/servlet engine.

In fact, it's counter productive to run things through wicket that it d/n
need to handle. You are just wasting resources.  (It caches stuff and even
minimal processing is  than no processing).

Another idea - move static stuff to another cheap server and point html to
pick up stuff (images) there. Could save you resources (bandwidth, cpu, ram
etc) and improve performance (most browsers limit number of simultaneous
threads to 1 server). 


-Original Message-
From: Pedro Santos [mailto:pedros...@gmail.com] 
Sent: Friday, November 13, 2009 10:30 AM
To: users@wicket.apache.org
Subject: Re: page without class

Only put then on top-level directory of a web module.
http://java.sun.com/javaee/5/docs/tutorial/doc/bnadx.html#bnadz

On Fri, Nov 13, 2009 at 1:21 PM, tubin gen fachh...@gmail.com wrote:

 can I create a page just with html  and not write class ? I need some
 static
 html pages and writing java for those will be of no use .




-- 
Pedro Henrique Oliveira dos Santos


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



RE: page without class

2009-11-13 Thread Alex Rass
Oh, for that...
Try messing with:

getRequestCycle().setRequestTarget(new
RedirectRequestTarget(access-in-denial.html));


-Original Message-
From: fachhoch [mailto:fachh...@gmail.com] 
Sent: Friday, November 13, 2009 11:36 AM
To: users@wicket.apache.org
Subject: Re: page without class


Ok I have to tell that page to my IApplicationSettings

IApplicationSettings settings=
super.getApplicationSettings();
settings.setAccessDeniedPage(accessDeniedPage)
here accessDeniedPage page is a static html page and I dont need java .
 I am talking about a wicket page without a class  just html  is it possible
?



Pedro H. O. dos Santos wrote:
 
 Only put then on top-level directory of a web module.
 http://java.sun.com/javaee/5/docs/tutorial/doc/bnadx.html#bnadz
 
 On Fri, Nov 13, 2009 at 1:21 PM, tubin gen fachh...@gmail.com wrote:
 
 can I create a page just with html  and not write class ? I need some
 static
 html pages and writing java for those will be of no use .

 
 
 
 -- 
 Pedro Henrique Oliveira dos Santos
 
 

-- 
View this message in context:
http://old.nabble.com/page-without-class-tp26338268p26339453.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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



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



RE: page without class

2009-11-13 Thread Alex Rass
... Or by overwriting how page requests are handled.

-Original Message-
From: Jeremy Thomerson [mailto:jer...@wickettraining.com] 
Sent: Friday, November 13, 2009 1:14 PM
To: users@wicket.apache.org
Subject: Re: page without class

No.  Although you can create a single page (java class) that can serve
multiple html pages if you'd like - either through panels or style
variation.

--
Jeremy Thomerson
http://www.wickettraining.com



On Fri, Nov 13, 2009 at 12:11 PM, fachhoch fachh...@gmail.com wrote:


 I am asking about creating a wicket page without a  class , can I create a
 org.apache.wicket.markup.html.WebPage  instance without any additional
 java file   just html  ?




 insom wrote:
 
  I believe you can do this if you change the Wicket filter mapping in
your
  web.xml to something other than /*. Then Tomcat will serve the page and
  bypass Wicket entirely.
 
  Dane
 
 
  On Fri, Nov 13, 2009 at 8:36 AM, fachhoch fachh...@gmail.com wrote:
 
 
  Ok I have to tell that page to my IApplicationSettings
 
 IApplicationSettings settings=
  super.getApplicationSettings();
 settings.setAccessDeniedPage(accessDeniedPage)
  here accessDeniedPage page is a static html page and I dont need java .
   I am talking about a wicket page without a class  just html  is it
  possible
  ?
 
 
 
  Pedro H. O. dos Santos wrote:
  
   Only put then on top-level directory of a web module.
   http://java.sun.com/javaee/5/docs/tutorial/doc/bnadx.html#bnadz
  
   On Fri, Nov 13, 2009 at 1:21 PM, tubin gen fachh...@gmail.com
 wrote:
  
   can I create a page just with html  and not write class ? I need
some
   static
   html pages and writing java for those will be of no use .
  
  
  
  
   --
   Pedro Henrique Oliveira dos Santos
  
  
 
  --
  View this message in context:
  http://old.nabble.com/page-without-class-tp26338268p26339453.html
  Sent from the Wicket - User mailing list archive at Nabble.com.
 
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 
 

 --
 View this message in context:
 http://old.nabble.com/page-without-class-tp26338268p26340879.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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




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



Security/login for pages?

2009-11-13 Thread Alex Rass
I need a rather simple authentication added to some of my screens.

Is WASP still the way to go?
Or are there newer/better things now?
http://wicketstuff.org/confluence/display/STUFFWIKI/Wicket-Security


I could write my own with a panel, 2 tables and a hammer, but I'd rather use
something proper with better future reusability.

PS: I've seen what the 2 wicket books out there offer and it's... sh*t. This
day and age page security shouldn't be an afterthought.

Thanks.
- Alex.


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



RE: (Frank) page without class

2009-11-13 Thread Alex Rass
Frank,

They/he/she wants to just serve static content w/o being probed by wicket.
It's there, it's possible, read rest of the threads on it.

Yeah, the poster wasn't clear at all at first as to what was needed. It's
better further you read.

-Original Message-
From: Frank Silbermann [mailto:frank.silberm...@fedex.com] 
Sent: Friday, November 13, 2009 3:21 PM
To: users@wicket.apache.org
Subject: RE: page without class

I don't know, but I wouldn't be surprised if the answer is no.

A foundational assumption about the way Wicket works is that a WebPage
object would result from the combination of a WebPage class with a
matching HTML file.  When Wicket sees MyPage.html in MyPackage with no
matching class, it assumes the class is erroneously missing.  You want
instead that Wicket should assume the class:

package MyPackage
class MyPage extends org.apache.wicket.markup.html.WebPage {}

I don't think the convenience of avoiding this two-line MyPage.java file
justifies eliminating this error check.

I suppose Wicket could provide an API command to tell it to assume a
trivial MyPage.java for MyPage.html, but I don't think such an API call
would save you all that many keystrokes over the two-line class
definition. 

-Original Message-
From: fachhoch [mailto:fachh...@gmail.com] 
Sent: Friday, November 13, 2009 12:12 PM
To: users@wicket.apache.org
Subject: Re: page without class


I am asking about creating a wicket page without a  class , can I create
a  
org.apache.wicket.markup.html.WebPage  instance without any additional  
java file   just html  ?




insom wrote:
 
 I believe you can do this if you change the Wicket filter mapping in
your
 web.xml to something other than /*. Then Tomcat will serve the page
and
 bypass Wicket entirely.
 
 Dane
 
 
 On Fri, Nov 13, 2009 at 8:36 AM, fachhoch fachh...@gmail.com wrote:
 

 Ok I have to tell that page to my IApplicationSettings

IApplicationSettings settings=
 super.getApplicationSettings();
settings.setAccessDeniedPage(accessDeniedPage)
 here accessDeniedPage page is a static html page and I dont need java
.
  I am talking about a wicket page without a class  just html  is it
 possible
 ?



 Pedro H. O. dos Santos wrote:
 
  Only put then on top-level directory of a web module.
  http://java.sun.com/javaee/5/docs/tutorial/doc/bnadx.html#bnadz
 
  On Fri, Nov 13, 2009 at 1:21 PM, tubin gen fachh...@gmail.com
wrote:
 
  can I create a page just with html  and not write class ? I need
some
  static
  html pages and writing java for those will be of no use .
 
 
 
 
  --
  Pedro Henrique Oliveira dos Santos
 
 

 --
 View this message in context:
 http://old.nabble.com/page-without-class-tp26338268p26339453.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


 
 

-- 
View this message in context:
http://old.nabble.com/page-without-class-tp26338268p26340879.html
Sent from the Wicket - User mailing list archive at Nabble.com.


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


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



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



RE:(Igor) page without class

2009-11-13 Thread Alex Rass


You could also create an interface to EVERY class in Wicket (as OO
suggests). ;)
Is there a point in doing it though?
If you are NOT handling something - let Tomcat(or whomever) deal with it!
Works GREAT for me, btw. 1/2 of my pages are static + all the image
resources and other crap.  This behavior is the default, btw.

Why waste a CPU on serving static stuff that you do NOT want handled or
massaged?  Your container will do a better job at it anyways. (see the
papers on tomcat and jetty competing on that point alone!) Let them deal
with it.

And if you DO want it handled - one can write a StaticContentPage class
(overwrite page handling methods in WebPage class).
Unless you just wanna serve it from ELSEWHERE, in which case - just
configure the apps server, like with any other j2ee project.


-Original Message-
From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com] 
Sent: Friday, November 13, 2009 3:50 PM
To: users@wicket.apache.org
Subject: Re: page without class

add an rfe to have it changed to take an irequesttarget instead of a
page class, that way you can do whatever you want.

-igor

On Fri, Nov 13, 2009 at 12:21 PM, Frank Silbermann
frank.silberm...@fedex.com wrote:
 I don't know, but I wouldn't be surprised if the answer is no.

 A foundational assumption about the way Wicket works is that a WebPage
 object would result from the combination of a WebPage class with a
 matching HTML file.  When Wicket sees MyPage.html in MyPackage with no
 matching class, it assumes the class is erroneously missing.  You want
 instead that Wicket should assume the class:

 package MyPackage
 class MyPage extends org.apache.wicket.markup.html.WebPage {}

 I don't think the convenience of avoiding this two-line MyPage.java file
 justifies eliminating this error check.

 I suppose Wicket could provide an API command to tell it to assume a
 trivial MyPage.java for MyPage.html, but I don't think such an API call
 would save you all that many keystrokes over the two-line class
 definition.

 -Original Message-
 From: fachhoch [mailto:fachh...@gmail.com]
 Sent: Friday, November 13, 2009 12:12 PM
 To: users@wicket.apache.org
 Subject: Re: page without class


 I am asking about creating a wicket page without a  class , can I create
 a
 org.apache.wicket.markup.html.WebPage  instance without any additional
 java file   just html  ?




 insom wrote:

 I believe you can do this if you change the Wicket filter mapping in
 your
 web.xml to something other than /*. Then Tomcat will serve the page
 and
 bypass Wicket entirely.

 Dane


 On Fri, Nov 13, 2009 at 8:36 AM, fachhoch fachh...@gmail.com wrote:


 Ok I have to tell that page to my IApplicationSettings

                IApplicationSettings settings=
 super.getApplicationSettings();
                settings.setAccessDeniedPage(accessDeniedPage)
 here accessDeniedPage page is a static html page and I dont need java
 .
  I am talking about a wicket page without a class  just html  is it
 possible
 ?



 Pedro H. O. dos Santos wrote:
 
  Only put then on top-level directory of a web module.
  http://java.sun.com/javaee/5/docs/tutorial/doc/bnadx.html#bnadz
 
  On Fri, Nov 13, 2009 at 1:21 PM, tubin gen fachh...@gmail.com
 wrote:
 
  can I create a page just with html  and not write class ? I need
 some
  static
  html pages and writing java for those will be of no use .
 
 
 
 
  --
  Pedro Henrique Oliveira dos Santos
 
 

 --
 View this message in context:
 http://old.nabble.com/page-without-class-tp26338268p26339453.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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





 --
 View this message in context:
 http://old.nabble.com/page-without-class-tp26338268p26340879.html
 Sent from the Wicket - User mailing list archive at Nabble.com.


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


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



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



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



RE: HTML Editing component

2009-11-12 Thread Alex Rass
I am an oldie, I use *ant* and hate maven.  Every time I have to touch it -
something blows up (your brix demo stopped working after a week ;) )

I downloaded the entire wicket-stuff repo instead.
That worked great until it died on jazzyplugin
All docs say that it's inclided. But it d/n seem to be.

Ideas?

Would love to find out how to mod pom file Or how to fix above problem.

Thanks.

-Original Message-
From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com] 
Sent: Thursday, November 12, 2009 2:59 AM
To: users@wicket.apache.org
Subject: Re: HTML Editing component

and make sure you check out the entire tinymce hierarchy and mvn
install  from the root

-igor

On Wed, Nov 11, 2009 at 11:58 PM, Igor Vaynberg igor.vaynb...@gmail.com
wrote:
 you need to add wicketstuff repo to your repositories pom tag

 -igor

 On Wed, Nov 11, 2009 at 11:48 PM, Alex Rass a...@itbsllc.com wrote:
 Went to the page (thanks!) got the SVN copy down.
 Ran Maven.
 Maven blows up with an error (below).
 Anyone knows how to get past this (or can fix it).

 Thanks.

 Output from running maven is here:

 G:\comp\apache-wicket-1.4.1\tinymce\comp\maven\bin\mvn
 [INFO] Scanning for projects...
 [INFO]
 
 [ERROR] FATAL ERROR
 [INFO]
 
 [INFO] Failed to resolve artifact.

 GroupId: org.wicketstuff
 ArtifactId: tinymce-parent
 Version: 1.4-SNAPSHOT

 Reason: Unable to download the artifact from any repository

  org.wicketstuff:tinymce-parent:pom:1.4-SNAPSHOT

 from the specified remote repositories:
  central (http://repo1.maven.org/maven2)



 [INFO]
 
 [INFO] Trace
 org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
 org.wicketstuff:tinymce-parent
  for project: null:tinymce:jar:null for project null:tinymce:jar:null



 -Original Message-
 From: Sam Barrow [mailto:s...@sambarrow.com]
 Sent: Wednesday, November 11, 2009 8:13 PM
 To: users@wicket.apache.org
 Subject: Re: HTML Editing component

 TinyMCE is one of the most popular out there, it has some wicket
 integration already done

http://wicketstuff.org/confluence/display/STUFFWIKI/wicket-contrib-tinymce


 On Wed, 2009-11-11 at 20:02 -0500, Alex Rass wrote:
 Hi.

 Hi.

 Did a bit of googling, but didn't find anything good...

 Anyone ever had to create an edit screen where you can do html/source
 editor?

 Any idea what I can use?

 In other words: I store html in database.
 I would like to be able to let my users bring it up inside a wicket
 screen.
 Edit html as pretty text (and not as bunch of markup)
 And post it back into the database.

 What I am looking for is the a component I can use from inside Wicket
 instead of TextField()

 Any ideas? I'd prefer one where I have access to source as well as
 pretty
 (plenty of them around where it's a 2-tab edit component).

 Thanks in advance.

 I saw something about TinyMCE in some forums...

 - Alex.


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



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



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




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



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



To WASP or not to WASP?

2009-11-12 Thread Alex Rass
I need a rather simple authentication added to some of my screens.

Is WASP still the way to go?
Or are there newer/better things now?
http://wicketstuff.org/confluence/display/STUFFWIKI/Wicket-Security

Thanks.


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



HTML Editing component

2009-11-11 Thread Alex Rass
Hi.

Hi.

Did a bit of googling, but didn't find anything good...

Anyone ever had to create an edit screen where you can do html/source
editor?

Any idea what I can use?

In other words: I store html in database.
I would like to be able to let my users bring it up inside a wicket screen.
Edit html as pretty text (and not as bunch of markup)
And post it back into the database.

What I am looking for is the a component I can use from inside Wicket
instead of TextField()

Any ideas? I'd prefer one where I have access to source as well as pretty
(plenty of them around where it's a 2-tab edit component).

Thanks in advance.

I saw something about TinyMCE in some forums...

- Alex.


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



RE: HTML Editing component

2009-11-11 Thread Alex Rass
Went to the page (thanks!) got the SVN copy down.
Ran Maven.
Maven blows up with an error (below).
Anyone knows how to get past this (or can fix it).

Thanks.

Output from running maven is here:

G:\comp\apache-wicket-1.4.1\tinymce\comp\maven\bin\mvn
[INFO] Scanning for projects...
[INFO]

[ERROR] FATAL ERROR
[INFO]

[INFO] Failed to resolve artifact.

GroupId: org.wicketstuff
ArtifactId: tinymce-parent
Version: 1.4-SNAPSHOT

Reason: Unable to download the artifact from any repository

  org.wicketstuff:tinymce-parent:pom:1.4-SNAPSHOT

from the specified remote repositories:
  central (http://repo1.maven.org/maven2)



[INFO]

[INFO] Trace
org.apache.maven.reactor.MavenExecutionException: Cannot find parent:
org.wicketstuff:tinymce-parent
 for project: null:tinymce:jar:null for project null:tinymce:jar:null



-Original Message-
From: Sam Barrow [mailto:s...@sambarrow.com] 
Sent: Wednesday, November 11, 2009 8:13 PM
To: users@wicket.apache.org
Subject: Re: HTML Editing component

TinyMCE is one of the most popular out there, it has some wicket
integration already done
http://wicketstuff.org/confluence/display/STUFFWIKI/wicket-contrib-tinymce


On Wed, 2009-11-11 at 20:02 -0500, Alex Rass wrote:
 Hi.
 
 Hi.
 
 Did a bit of googling, but didn't find anything good...
 
 Anyone ever had to create an edit screen where you can do html/source
 editor?
 
 Any idea what I can use?
 
 In other words: I store html in database.
 I would like to be able to let my users bring it up inside a wicket
screen.
 Edit html as pretty text (and not as bunch of markup)
 And post it back into the database.
 
 What I am looking for is the a component I can use from inside Wicket
 instead of TextField()
 
 Any ideas? I'd prefer one where I have access to source as well as
pretty
 (plenty of them around where it's a 2-tab edit component).
 
 Thanks in advance.
 
 I saw something about TinyMCE in some forums...
 
 - Alex.
 
 
 -
 To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
 For additional commands, e-mail: users-h...@wicket.apache.org
 


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



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



RE: Combination CompoundPropertyModel and ChoiceRenderer on DropDownChoice gives problems

2009-11-09 Thread Alex Rass
I am a newb here, so I may be way off, but this works for me:

public final static ChoiceRenderer listRenderer = new
ChoiceRenderer(description, id);

Expose description and id on your model's object.

And just add the listRenderer to the DDChoice (last param).
Seems a lot simpler than what you are doing.


-Original Message-
From: Xavier López [mailto:xavil...@gmail.com] 
Sent: Monday, November 09, 2009 9:37 AM
To: users@wicket.apache.org
Subject: Re: Combination CompoundPropertyModel and ChoiceRenderer on
DropDownChoice gives problems

Got it!

Here is the code i got into. Improvements and critics are welcome !

class MappedModel extends Model {
protected Map map;
public String getDescription(Object id){
return (String) map.get(id);
}
}

// Localized choices
final MappedModel countryModel = new MappedModel(){
public Object getObject() {
super.map = referenceData.getCountries(getLanguage());
return new ArrayList(super.map.keySet());
}
};
DropDownChoice ddcCountry= new
DropDownChoice(country,countryModel);
ddcCountry.setChoiceRenderer(new IChoiceRenderer() {
   public Object getDisplayValue(Object object) {
   return countryModel.getDescription(object);
   }
   public String getIdValue(Object object, int index) {
   return object.toString();
   }
});


Thanks to everyone on this list not only for the heads up on this one but
for many more I did not need to ask ;)


2009/11/9 Xavier López xavil...@gmail.com

 Hi Sven,

 Absolutely awesome. So sweet how problems vanish away when you know the
 right way to address them on Wicket: ).

 But, what if I had a list of countries in the database (better example
than
 gender in this case), with its descriptions in it? Should I store a
Country
 entity in my bean, instead of simply and Id (taking into account this
entity
 possibly contains the descriptions and other unuseful stuff) ? Could I
 manage someway, using the countryId's in the ddc's choiceList model, to
look
 for those descriptions in i.e. a memory-stored Map ?

 Thanks a lot!
 Xavier

 2009/11/9 svenmeier s...@meiers.net


 You want to select one value from a list of values, so obviously
 everything
 has to have the same type.

 These 'IdDescrBeans' smell like Struts, such constructs are not needed.
 What's wrong with the following:

  ListString genders = new ArrayListString();
  list.add(M);
  list.add(F);
  form.add(new DropDownChoice(gender, genders) {
protected boolean localizeDisplayValues() {
  return true;
}
  });

 Creating an enum would be a nice alternative to strings though.
 Put the following keys in you page's property file:

  gender.M = male
  gender.F = female

 i18n for free.

 Sven


 Xavier López-2 wrote:
 
  Hi Ann,
 
  I've also encountered this problem, but with RadioChoice instead of
  DropDownChoice.
 
  This is the thread I started about it:
 
 
 http://mail-archives.apache.org/mod_mbox/wicket-users/200911.mbox/browser
 
  After all this thread, I still don't know what should I do to model,
for
  instance, a gender radioChoice which would be backed by a String
 property
  (M of F), providing a list of choices (multilingual) with
 IdDescrBeans
  like you propose.
  Should I change my bean's 'String gender' property to 'IdDescrBean
 gender'
  ?
  Why should I store description's information on my model entity ?
 
  Although I agree with having same object's on choices and model when
 it's
  about more complex data...
 
  Possible solutions I've thought of so far:
 
 - Ideally, do not use different object types in
 compundpropertymodel's
 bean and choice List. Use same object type instead.
 - When using RadioChoice, it works if you substitute it with a
  RadioGroup
 and Radio's, using the 'id' property as the Radio's model and the
 'description' property as the label's model. However, when it's
about
 DropDownChoice, I'm clueless about it at the moment (already having
  problems
 with them).
 - Provide a list of choices in which each element is an Id, and then
 provide a ChoiceRenderer display expression such that gets the
proper
 description (I don't like that at all).
 - Modify IdDescrBean so that it returns the 'id' property in its
 'toString' method, and, assuming the compundpropertymodel's bean
  related
 property is String, provide an implementation for some useless
method
 ('trim' for example), so that it returns the desctiption. Then, in
 the
 ChoiceRenderer, you can set the displayExpression to 'trim()', which
  will
 ensure that when the component model's object is a String, this
error
  will
 not happen (also, it will return the trimmed id as description, but
  that
 will have no effect). But there is more to it, in order to achieve
 

RE: Migrating wivket app from 1.2.4 to 1.4.3

2009-11-04 Thread Alex Rass
They don't cover some breaks in AjaxFallbackDefaultDataTable interfaces.
If you don't use those - it's an easy conversion.
Make sure you do a clean recompile and it will show you what's broken.

Seems like 1.5 is around the corner... May want to wait a little. Though it
seems from the messages that 1.4.x - 1.5 should be easy. 

-Original Message-
From: Igor Vaynberg [mailto:igor.vaynb...@gmail.com] 
Sent: Wednesday, November 04, 2009 1:14 AM
To: users@wicket.apache.org
Subject: Re: Migrating wivket app from 1.2.4 to 1.4.3

our wiki contains migration pages for 1.2 to 1.3 and 1.3 to 1.4

-igor

On Tue, Nov 3, 2009 at 9:17 PM, Shankar Subedi shankar.sub...@gmail.com
wrote:
 Hello all,
 I had build an application on wicket 1.2.4, spring and hibernate some
about
 2 years before.
 Now i think, i need to upgrade wicket.

 Since there are number of releases in between those version, I think there
 are many modifications to be done.
 Please show me the way..


 Thanks in advance

 Regards
 shankar


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



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



RE: Scala, dependency injection and wicket

2009-10-07 Thread Alex Rass
This is similar problem to one I'm trying to solve.
Mine's: having several html files have the same java class controlling them.
(sounds simple, right?)

So far the only reasonable thing came from Martin and that's to override
getAssociatedMarkupStream in your own Page class.

Which also implies rewriting cache useage etc.

Wanna do it together or smth?

I'm new to wicket myself. And so far: ajax is a pain in the ass that
requires explicit work even for a simple form verification (bad architecture
there). And this other problem with url formation. Just hoping they didn't
go nuts making stuff final, like apache usually does ;)

-Original Message-
From: Haim Ashkenazi [mailto:haim.ashken...@gmail.com] 
Sent: Wednesday, October 07, 2009 10:51 AM
To: users@wicket.apache.org
Subject: Scala, dependency injection and wicket

Hi

I've started a test project on which I use scala, wicket and couchdb (I'm
new to all of them, which should make it fun :) ).

Until now I was dealing with the writing sample data access code, and I was
reading a lot of articles about DI in scala. I more or less went with what
is suggested in the Programing in scala book, that is using traits with
self type annotations and lazy vals (for calling modules). It's very easy to
construct object/classes for testing this way. Now I reached the web part
(wicket) and I came to a problem. In wicket the class name *has* to match
the html file (e.g. package/HomePage.html must have a corresponding
package.HomePage.class). This makes it (I think) impossible to use the above
method for DI.

One solution is to use DI framework like guice, but I was wondering if
someone hear has other idea?

Thanks in advance
-- 
Haim


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



how to map 2 html files to 1 class?

2009-10-05 Thread Alex Rass
Hi.

Spent hours now trying to figure out how to map 2 html files to 1 class.
If someone knows the answer - please help.

I need to map 10 similar html pages to same class (for same behavior).

Doing this:
webApplication.mountBookmarkablePage(/page1.html, pageClass);
Gets wicket to associate set url with the class.
But then when the ResourceStreamLocator is called, it's given
A reference to class and a reference to the path. Where class is set
correctly (pageClass).
But the PATH is set wrong. It is what Wicket THINKS it should try
PageClass_en.html. (class name + locale + default extension)

While *I* would like to load my own class.

I was thinking about completely rewriting ResourceStreamLocator to know my
own paths, BUT it's not aware of what real page is being loaded (as the path
is set to PageClass_en.html).

I could also break down and load my own stuff in beforeRender, but I was
hoping there's a better way to handle this.

Lastly, I could overwrite onRender() in my PageClass... 

Any advice would be much appreciated.

- Alex.


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



RE: how to map 2 html files to 1 class?

2009-10-05 Thread Alex Rass
Yeah, that's what I had before. (Many fake classes that do nothing but
extend default one).
But I have multiple sites. With lots of pages. I don't want to have 200
classes that serve no purpose! (I already have 30 like that for my first
couple sites :) was hoping to stop this silly practice) (hold the jokes
about there aren't many classes that can claim to have a purpose :) )

This thing about PageContantHandler intrigues me as this is exactly what I
need, but I don't understand how this would work. Unless this is your way of
asking the question. If so, here's what I want:


domain.com/PageA.html
domain.com/PageB.html
domain.com/PageC.html
(all files are locally on my site, just to keep it clear.)

PageHandler.java, that handles all 3.
mountBookmarkablePage(/PageA.html, PageHandler.class);
mountBookmarkablePage(/PageB.html, PageHandler.class);
mountBookmarkablePage(/PageC.html, PageHandler.class);




-Original Message-
From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com] 
Sent: Monday, October 05, 2009 5:23 PM
To: users@wicket.apache.org
Subject: Re: how to map 2 html files to 1 class?

And ofcourse you could have polymorphism.

AbstractPageWithDesiredCommonFunctionality.java with all your common logic,

Page1Design extends AbstractPageWithDesiredCommonFunctionality
Page2Design extends AbstractPageWithDesiredCommonFunctionality
 :
 :
 :
Page-n-Design extends AbstractPageWithDesiredCommonFunctionality

And also the html would be
Page1Design.html
Page2Design.html
 :
 :
 :
Page-n-Design.html


**
Martin

2009/10/6 Martin Makundi martin.maku...@koodaripalvelut.com:
 It's too late :) Apparently you wanted just the opposite.

 Well.. you could have:

 PageA.html:
 PageB.html:
 PageC.html:

 Page?.java:
 public class CommonPage extends WebPage {
  public CommonPage() {
      new PageContantHandler(this);
  }
 }

 **
 Martin

 2009/10/6 Martin Makundi martin.maku...@koodaripalvelut.com:
 Hi!

 I did not exactly understand what you are after, but you can always do
 like this:

 CommonPage.html:
  blabla ...

 CommonPage.java:
 public class CommonPage extends WebPage {
  public CommonPage() {
     if (A-mode) {
       new PageVersionAContantHandler(this);
     } else {
       new PageVersionAContantHandler(this);
     }
  }
 }

 Maybe you wanted something different?

 **
 Martin

 2009/10/6 Alex Rass a...@itbsllc.com:
 Hi.

 Spent hours now trying to figure out how to map 2 html files to 1 class.
 If someone knows the answer - please help.

 I need to map 10 similar html pages to same class (for same behavior).

 Doing this:
 webApplication.mountBookmarkablePage(/page1.html, pageClass);
 Gets wicket to associate set url with the class.
 But then when the ResourceStreamLocator is called, it's given
 A reference to class and a reference to the path. Where class is set
 correctly (pageClass).
 But the PATH is set wrong. It is what Wicket THINKS it should try
 PageClass_en.html. (class name + locale + default extension)

 While *I* would like to load my own class.

 I was thinking about completely rewriting ResourceStreamLocator to know
my
 own paths, BUT it's not aware of what real page is being loaded (as the
path
 is set to PageClass_en.html).

 I could also break down and load my own stuff in beforeRender, but I was
 hoping there's a better way to handle this.

 Lastly, I could overwrite onRender() in my PageClass...

 Any advice would be much appreciated.

 - Alex.


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





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



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



RE: how to map 2 html files to 1 class?

2009-10-05 Thread Alex Rass
I don't see how this applies.
Please note that ResourceStreamLocator does not see the original url's path.
And Page uses a cacheKey which is solely based on the class name.

Maybe you can elaborate, but all 3 html files are TOTALLY UNRELATED PAGES.
It's not the same page 3 times for diff skins. All 3 need to be available at
the same time. (Should have made it clear earlier). 


-Original Message-
From: Scott Swank [mailto:scott.sw...@gmail.com] 
Sent: Monday, October 05, 2009 5:38 PM
To: users@wicket.apache.org
Subject: Re: how to map 2 html files to 1 class?

Have you considered using variant or style?

http://cwiki.apache.org/WICKET/localization-and-skinning-of-applications.htm
l

Scott

On Mon, Oct 5, 2009 at 2:35 PM, Alex Rass a...@itbsllc.com wrote:
 Yeah, that's what I had before. (Many fake classes that do nothing but
 extend default one).
 But I have multiple sites. With lots of pages. I don't want to have 200
 classes that serve no purpose! (I already have 30 like that for my first
 couple sites :) was hoping to stop this silly practice) (hold the jokes
 about there aren't many classes that can claim to have a purpose :) )

 This thing about PageContantHandler intrigues me as this is exactly what I
 need, but I don't understand how this would work. Unless this is your way
of
 asking the question. If so, here's what I want:


 domain.com/PageA.html
 domain.com/PageB.html
 domain.com/PageC.html
 (all files are locally on my site, just to keep it clear.)

 PageHandler.java, that handles all 3.
 mountBookmarkablePage(/PageA.html, PageHandler.class);
 mountBookmarkablePage(/PageB.html, PageHandler.class);
 mountBookmarkablePage(/PageC.html, PageHandler.class);




 -Original Message-
 From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com]
 Sent: Monday, October 05, 2009 5:23 PM
 To: users@wicket.apache.org
 Subject: Re: how to map 2 html files to 1 class?

 And ofcourse you could have polymorphism.

 AbstractPageWithDesiredCommonFunctionality.java with all your common
logic,

 Page1Design extends AbstractPageWithDesiredCommonFunctionality
 Page2Design extends AbstractPageWithDesiredCommonFunctionality
  :
  :
  :
 Page-n-Design extends AbstractPageWithDesiredCommonFunctionality

 And also the html would be
 Page1Design.html
 Page2Design.html
  :
  :
  :
 Page-n-Design.html


 **
 Martin

 2009/10/6 Martin Makundi martin.maku...@koodaripalvelut.com:
 It's too late :) Apparently you wanted just the opposite.

 Well.. you could have:

 PageA.html:
 PageB.html:
 PageC.html:

 Page?.java:
 public class CommonPage extends WebPage {
  public CommonPage() {
      new PageContantHandler(this);
  }
 }

 **
 Martin

 2009/10/6 Martin Makundi martin.maku...@koodaripalvelut.com:
 Hi!

 I did not exactly understand what you are after, but you can always do
 like this:

 CommonPage.html:
  blabla ...

 CommonPage.java:
 public class CommonPage extends WebPage {
  public CommonPage() {
     if (A-mode) {
       new PageVersionAContantHandler(this);
     } else {
       new PageVersionAContantHandler(this);
     }
  }
 }

 Maybe you wanted something different?

 **
 Martin

 2009/10/6 Alex Rass a...@itbsllc.com:
 Hi.

 Spent hours now trying to figure out how to map 2 html files to 1
class.
 If someone knows the answer - please help.

 I need to map 10 similar html pages to same class (for same behavior).

 Doing this:
 webApplication.mountBookmarkablePage(/page1.html, pageClass);
 Gets wicket to associate set url with the class.
 But then when the ResourceStreamLocator is called, it's given
 A reference to class and a reference to the path. Where class is set
 correctly (pageClass).
 But the PATH is set wrong. It is what Wicket THINKS it should try
 PageClass_en.html. (class name + locale + default extension)

 While *I* would like to load my own class.

 I was thinking about completely rewriting ResourceStreamLocator to know
 my
 own paths, BUT it's not aware of what real page is being loaded (as the
 path
 is set to PageClass_en.html).

 I could also break down and load my own stuff in beforeRender, but I
was
 hoping there's a better way to handle this.

 Lastly, I could overwrite onRender() in my PageClass...

 Any advice would be much appreciated.

 - Alex.


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





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



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



-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org

RE: how to map 2 html files to 1 class?

2009-10-05 Thread Alex Rass
PageA.html  PageB.html  PageC.html

Think about it this way:
PageA.html  = Privacy Page 
PageB.html = SiteMap Page.

I want to handle them both in same java class file cause hardly anything
is going on there.


-Original Message-
From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com] 
Sent: Monday, October 05, 2009 6:08 PM
To: users@wicket.apache.org
Subject: Re: how to map 2 html files to 1 class?

 PageHandler.java, that handles all 3.
 mountBookmarkablePage(/PageA.html, PageHandler.class);
 mountBookmarkablePage(/PageB.html, PageHandler.class);
 mountBookmarkablePage(/PageC.html, PageHandler.class);

This is a bit confusing, you ar giving different aliases to the same
page. Is that what you want or you really want different html files
also..`?

**
Martin

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



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



RE: how to map 2 html files to 1 class?

2009-10-05 Thread Alex Rass
Scott,

Maybe I am not clear on how localization works, but what you are proposing
would work only if I needed ONE of the html files to be available at one
time/session to same user.

What I want is:

3 html files. Called up via 3 distinct predefined urls. All handled by 1
class.

As far as I can tell from reading a ton of code today: anything beyond the
Page class has no idea as to what URL was called up by the user, just the
class. And from that class, it finds variations of url name based on class's
name.

I have a many:one mapping. Many html files to one class.
No way to find out from class - which URL was requested.

Page class knows the url through the getRequest. No one further has any
idea.

Again, that's just what I read. Which is why I am here


-Original Message-
From: Scott Swank [mailto:scott.sw...@gmail.com] 
Sent: Monday, October 05, 2009 5:56 PM
To: users@wicket.apache.org
Subject: Re: how to map 2 html files to 1 class?

But if all three html files are associated with the same Java class,
how does this differ from separate skins?  Is the distinction
semantic, or am I missing something?

Scott

On Mon, Oct 5, 2009 at 2:44 PM, Alex Rass a...@itbsllc.com wrote:
 I don't see how this applies.
 Please note that ResourceStreamLocator does not see the original url's
path.
 And Page uses a cacheKey which is solely based on the class name.

 Maybe you can elaborate, but all 3 html files are TOTALLY UNRELATED PAGES.
 It's not the same page 3 times for diff skins. All 3 need to be available
at
 the same time. (Should have made it clear earlier).


 -Original Message-
 From: Scott Swank [mailto:scott.sw...@gmail.com]
 Sent: Monday, October 05, 2009 5:38 PM
 To: users@wicket.apache.org
 Subject: Re: how to map 2 html files to 1 class?

 Have you considered using variant or style?


http://cwiki.apache.org/WICKET/localization-and-skinning-of-applications.htm
 l

 Scott

 On Mon, Oct 5, 2009 at 2:35 PM, Alex Rass a...@itbsllc.com wrote:
 Yeah, that's what I had before. (Many fake classes that do nothing but
 extend default one).
 But I have multiple sites. With lots of pages. I don't want to have 200
 classes that serve no purpose! (I already have 30 like that for my first
 couple sites :) was hoping to stop this silly practice) (hold the jokes
 about there aren't many classes that can claim to have a purpose :) )

 This thing about PageContantHandler intrigues me as this is exactly what
I
 need, but I don't understand how this would work. Unless this is your way
 of
 asking the question. If so, here's what I want:


 domain.com/PageA.html
 domain.com/PageB.html
 domain.com/PageC.html
 (all files are locally on my site, just to keep it clear.)

 PageHandler.java, that handles all 3.
 mountBookmarkablePage(/PageA.html, PageHandler.class);
 mountBookmarkablePage(/PageB.html, PageHandler.class);
 mountBookmarkablePage(/PageC.html, PageHandler.class);




 -Original Message-
 From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com]
 Sent: Monday, October 05, 2009 5:23 PM
 To: users@wicket.apache.org
 Subject: Re: how to map 2 html files to 1 class?

 And ofcourse you could have polymorphism.

 AbstractPageWithDesiredCommonFunctionality.java with all your common
 logic,

 Page1Design extends AbstractPageWithDesiredCommonFunctionality
 Page2Design extends AbstractPageWithDesiredCommonFunctionality
  :
  :
  :
 Page-n-Design extends AbstractPageWithDesiredCommonFunctionality

 And also the html would be
 Page1Design.html
 Page2Design.html
  :
  :
  :
 Page-n-Design.html


 **
 Martin

 2009/10/6 Martin Makundi martin.maku...@koodaripalvelut.com:
 It's too late :) Apparently you wanted just the opposite.

 Well.. you could have:

 PageA.html:
 PageB.html:
 PageC.html:

 Page?.java:
 public class CommonPage extends WebPage {
  public CommonPage() {
      new PageContantHandler(this);
  }
 }

 **
 Martin

 2009/10/6 Martin Makundi martin.maku...@koodaripalvelut.com:
 Hi!

 I did not exactly understand what you are after, but you can always do
 like this:

 CommonPage.html:
  blabla ...

 CommonPage.java:
 public class CommonPage extends WebPage {
  public CommonPage() {
     if (A-mode) {
       new PageVersionAContantHandler(this);
     } else {
       new PageVersionAContantHandler(this);
     }
  }
 }

 Maybe you wanted something different?

 **
 Martin

 2009/10/6 Alex Rass a...@itbsllc.com:
 Hi.

 Spent hours now trying to figure out how to map 2 html files to 1
 class.
 If someone knows the answer - please help.

 I need to map 10 similar html pages to same class (for same behavior).

 Doing this:
 webApplication.mountBookmarkablePage(/page1.html, pageClass);
 Gets wicket to associate set url with the class.
 But then when the ResourceStreamLocator is called, it's given
 A reference to class and a reference to the path. Where class is set
 correctly (pageClass).
 But the PATH is set wrong. It is what Wicket THINKS it should try
 PageClass_en.html. (class name + locale

RE: how to map 2 html files to 1 class?

2009-10-05 Thread Alex Rass
Standardizing footers across the site.
So I will have a dozen pages which are bare content + footer from a common
file/db.
I don't want to have THAT many useless classes.  If I do - wicket is a
failure.

-Original Message-
From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com] 
Sent: Monday, October 05, 2009 6:27 PM
To: users@wicket.apache.org
Subject: Re: how to map 2 html files to 1 class?

What are you handling there ?

**
Martin

2009/10/6 Alex Rass a...@itbsllc.com:
 PageA.html  PageB.html  PageC.html

 Think about it this way:
 PageA.html  = Privacy Page
 PageB.html = SiteMap Page.

 I want to handle them both in same java class file cause hardly anything
 is going on there.


 -Original Message-
 From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com]
 Sent: Monday, October 05, 2009 6:08 PM
 To: users@wicket.apache.org
 Subject: Re: how to map 2 html files to 1 class?

 PageHandler.java, that handles all 3.
 mountBookmarkablePage(/PageA.html, PageHandler.class);
 mountBookmarkablePage(/PageB.html, PageHandler.class);
 mountBookmarkablePage(/PageC.html, PageHandler.class);

 This is a bit confusing, you ar giving different aliases to the same
 page. Is that what you want or you really want different html files
 also..`?

 **
 Martin

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



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



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



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



RE: how to map 2 html files to 1 class?

2009-10-05 Thread Alex Rass
Please read the posts in full.
GOAL: to not have 200 classes that do NOTHING but inherit from parent class
and are empty inside.

-Original Message-
From: Jeremy Thomerson [mailto:jer...@wickettraining.com] 
Sent: Monday, October 05, 2009 6:38 PM
To: users@wicket.apache.org
Subject: Re: how to map 2 html files to 1 class?

Do you use page inheritance?  The header / footer / common navbars should go
in a common parent class.  Then your child classes have only the content
that is unique to that class.

--
Jeremy Thomerson
http://www.wickettraining.com



On Mon, Oct 5, 2009 at 5:36 PM, Alex Rass a...@itbsllc.com wrote:

 Standardizing footers across the site.
 So I will have a dozen pages which are bare content + footer from a common
 file/db.
 I don't want to have THAT many useless classes.  If I do - wicket is a
 failure.

 -Original Message-
 From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com]
 Sent: Monday, October 05, 2009 6:27 PM
 To: users@wicket.apache.org
 Subject: Re: how to map 2 html files to 1 class?

 What are you handling there ?

 **
 Martin

 2009/10/6 Alex Rass a...@itbsllc.com:
  PageA.html  PageB.html  PageC.html
 
  Think about it this way:
  PageA.html  = Privacy Page
  PageB.html = SiteMap Page.
 
  I want to handle them both in same java class file cause hardly
 anything
  is going on there.
 
 
  -Original Message-
  From: Martin Makundi [mailto:martin.maku...@koodaripalvelut.com]
  Sent: Monday, October 05, 2009 6:08 PM
  To: users@wicket.apache.org
  Subject: Re: how to map 2 html files to 1 class?
 
  PageHandler.java, that handles all 3.
  mountBookmarkablePage(/PageA.html, PageHandler.class);
  mountBookmarkablePage(/PageB.html, PageHandler.class);
  mountBookmarkablePage(/PageC.html, PageHandler.class);
 
  This is a bit confusing, you ar giving different aliases to the same
  page. Is that what you want or you really want different html files
  also..`?
 
  **
  Martin
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 
 
  -
  To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
  For additional commands, e-mail: users-h...@wicket.apache.org
 
 

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



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




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