Re: What does your project directory structure look like?

2006-09-21 Thread soir

My multimodule project's directory structure looks like (it's suggested by
Maven):

workspace\projectname
workspace\projectname\src\main\java
workspace\projectname\src\main\resources
workspace\projectname\src\main\webapp
workspace\projectname\src\main\webapp\images
workspace\projectname\src\main\webapp\script
workspace\projectname\src\main\webapp\style
workspace\projectname\src\main\webapp\META-INF
workspace\projectname\src\main\webapp\WEB-INF
workspace\projectname\src\test\java
workspace\projectname\src\test\resources
workspace\projectname\target\classes


Daniel Jue wrote:
> 
> Hi,
> 
> I'm relatively new to Tap, and I am starting with Tap 4 and Eclipse.
> I've been using the directory structures as seen in Kent Tong's book.
> I also noticed the Tapestry examples (vlib and workbench) have html
> files that live in the root of the application, instead of in web-inf.
>  Is this a standard thing to do?
> 
> I've read that things inside web-inf can't be accessed directly by a
> web browser, so that seems like the correct place for the .page/.jwc's
> to go.
> 
> Like I said, I have something that _works_, I am just curious to see
> if there are benefits to other methods, or drawbacks to mine (i'm sure
> my approach is naive):
> 
> workspace\projectname
> workspace\projectname\build\classes (output dir for compiled classes)
> workspace\projectname\deploy (holds my war file when I export from
> eclipse)
> workspace\projectname\src\mypackage\ (no .java at this level)
> workspace\projectname\src\mypackage\model\ (classes that know nothing
> about tapestry)
> workspace\projectname\src\mypackage\controller\ (classes for pages and
> components)
> 
> workspace\projectname\src\META-INF\ (holds hivemind.xml and sessions.xml)
> 
> workspace\projectname\WebContent\css (css files)
> workspace\projectname\images (jpgs)
> workspace\projectname\META-INF (I think eclipse made this dir and
> manifest.mf for me)
> 
> workspace\projectname\WEB-INF (all my .html, .page and .jwc files live
> directly in WEB-INF, as well as projectname.application and web.xml)
> workspace\projectname\lib (hold jars for jscookmenu, BIRT, etc)
> 
> workspace\projectname\reporting\BIRT (holds birt engine, jars, resources,
> etc)
> 
> 
> When I export my project to a WAR, things in
> workspace\projectname\build\classes
> get put in
> WEB-INF\classes
> 
> Please let me know what you think. I'm sure you guys have better
> organized project structures.  For instance, do your Tapestry projects
> look like this?
> http://java.sun.com/blueprints/code/projectconventions.html
> 
> Daniel
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/What-does-your-project-directory-structure-look-like--tf2315087.html#a6441834
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: application namespace message catalog question

2006-09-21 Thread soir

I have same issue. Application-level message catalog is not accessible from
the components which are placed into same application library.


Scott Jarvi wrote:
> 
> Hi,
> 
> I have a component that makes use of localized messages that may be shared
> by other components and pages.  Because of this, I've put the keys in my
> application-level message catalog.  For some reason, the keys are not
> found
> when the component is rendered on my page.  This seems like it should be
> supported based on the documentation, so I must be missing something
> simple.  Any ideas??
> 
> Regards,
> Scott
> 
> 

-- 
View this message in context: 
http://www.nabble.com/application-namespace-message-catalog-question-tf2314010.html#a6441707
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: template and key

2006-09-21 Thread andyhot
See the tapestry user  guide, esp.
http://tapestry.apache.org/tapestry4/UsersGuide/template.html#template.directives.l10n

See the tacos user guide, esp.
http://tacos.sourceforge.net/userguide/MoreGoodies.html

edward pedersson wrote:
> Hi
>
> I have been looking at some tapestry examples and I noticed this notation
>
> 
>
> I figured this is related to the .properties file but how does this
> work? Is
> that documented anywhere?
>
>
> In addition I have also noticed the use of
>
>   selectedCountries:'[255,255,184], 500, 500',
>  '${currItem}':'[255,255,184], 500, 500'
>  }}" />
>
> is the template directive part of ognl or Tapestry and how does that
> work? I
> can't locate the documentation.
>
> Thanks
>


-- 
Andreas Andreou - [EMAIL PROTECTED] - http://andyhot.di.uoa.gr
Tapestry / Tacos developer
Open Source / J2EE Consulting 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Expired Session message

2006-09-21 Thread karthik.nar

Hey Greg,

Just curious - did you eventually solve this?  If so can you paste your
solution?

Thanks, Karthik.
-- 
View this message in context: 
http://www.nabble.com/Asynchronous-form-submission-tf2253801.html#a6441359
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



template and key

2006-09-21 Thread edward pedersson

Hi

I have been looking at some tapestry examples and I noticed this notation



I figured this is related to the .properties file but how does this work? Is
that documented anywhere?


In addition I have also noticed the use of



is the template directive part of ognl or Tapestry and how does that work? I
can't locate the documentation.

Thanks

--


-- e


Re: Tomcat restart through tapestry

2006-09-21 Thread Peter Dawn

sorry my bad. point taken.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat restart through tapestry

2006-09-21 Thread Jesse Kuhnert

Please...

Once again, move this to another list. I'm completely against censoring
people but this is getting a little silly.

On 9/21/06, Peter Dawn <[EMAIL PROTECTED]> wrote:


yes i am using tomcat as a service. and there is nothing called
restart command. i can only start, stop or continue.

but i have tried to execute a batch file, but due to browser
restrictions it wont let me to do that. when i click on the link it
doesnt do anything at all. but if i run that page standalone in HTML
it runs the batch file.

so i am kinda stuck.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Jesse Kuhnert
Tapestry/Dojo/(and a dash of TestNG), team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: Tomcat restart through tapestry

2006-09-21 Thread Peter Dawn

yes i am using tomcat as a service. and there is nothing called
restart command. i can only start, stop or continue.

but i have tried to execute a batch file, but due to browser
restrictions it wont let me to do that. when i click on the link it
doesnt do anything at all. but if i run that page standalone in HTML
it runs the batch file.

so i am kinda stuck.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat restart through tapestry

2006-09-21 Thread Jesse Kuhnert

Please move this thread somewhere else.. Like the tomcat users mailing list.


On 9/21/06, Peter Dawn <[EMAIL PROTECTED]> wrote:


sure will do. but its a funny problem. once you stop tomcat you cant
restart it again, coz without tomcat your application wont run in the
first place.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Jesse Kuhnert
Tapestry/Dojo/(and a dash of TestNG), team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: Tomcat restart through tapestry

2006-09-21 Thread Daniel Jue

So you need to restart the service from the app, not just stop it.  I
would think since the jvm Tomcat uses would disappear for a splits
second you would need to hand off control to a something non-java,
like a wsh so it can start the service afterwards.  Unless there is a
direct command you can give to Tomcat for "restart" that will handle
this for you without.
Or something like net restart  if you have it
installed as a service.

Daniel

On 9/21/06, Josh Joy <[EMAIL PROTECTED]> wrote:

Try looking into JMX MBeans. They provide a lot of
this and other
functionality.

Peter Dawn wrote:
> guys,
>
> i have run into this problem. i am able to stop
tomcat from the app. but,
> 1. if i have another button to start tomcat within
the app, then that
> command is not captured as tomcat is not running and
hence the web
> application is not running
> 2. if i execute a batch file, again the stop works
but it does not
> start again.
>
> any ideas.
>
>
-
> To unsubscribe, e-mail:
[EMAIL PROTECTED]
> For additional commands, e-mail:
[EMAIL PROTECTED]
>
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat restart through tapestry

2006-09-21 Thread Peter Dawn

sure will do. but its a funny problem. once you stop tomcat you cant
restart it again, coz without tomcat your application wont run in the
first place.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat restart through tapestry

2006-09-21 Thread Josh Joy
Try looking into JMX MBeans. They provide a lot of
this and other 
functionality.

Peter Dawn wrote:
> guys,
>
> i have run into this problem. i am able to stop
tomcat from the app. but,
> 1. if i have another button to start tomcat within
the app, then that
> command is not captured as tomcat is not running and
hence the web
> application is not running
> 2. if i execute a batch file, again the stop works
but it does not 
> start again.
>
> any ideas.
>
>
-
> To unsubscribe, e-mail:
[EMAIL PROTECTED]
> For additional commands, e-mail:
[EMAIL PROTECTED]
>
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Tomcat restart through tapestry

2006-09-21 Thread Peter Dawn

guys,

i have run into this problem. i am able to stop tomcat from the app. but,
1. if i have another button to start tomcat within the app, then that
command is not captured as tomcat is not running and hence the web
application is not running
2. if i execute a batch file, again the stop works but it does not start again.

any ideas.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Restart tomcat from within tapestry

2006-09-21 Thread Daniel Jue

Windows, with tomcat installed as a service (And that service probably
runs as SYSTEM)?  H. You could do it with pstools from
Sysinternals.com.  You could also probably do it from a net command
http://technet2.microsoft.com/WindowsServer/en/library/03928250-2796-4253-8fb1-b25329ddf35f1033.mspx?mfr=true

or calling a wsh script:

http://www.codecomments.com/archive300-2004-7-239797.html

If you didn't install it as a service, there should be a batch file to
do it for you. =)

Good luck and let us know what you chose.


On 9/21/06, Peter Dawn <[EMAIL PROTECTED]> wrote:

am using windows. so whats the location then. thanks.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



What does your project directory structure look like?

2006-09-21 Thread Daniel Jue

Hi,

I'm relatively new to Tap, and I am starting with Tap 4 and Eclipse.
I've been using the directory structures as seen in Kent Tong's book.
I also noticed the Tapestry examples (vlib and workbench) have html
files that live in the root of the application, instead of in web-inf.
Is this a standard thing to do?

I've read that things inside web-inf can't be accessed directly by a
web browser, so that seems like the correct place for the .page/.jwc's
to go.

Like I said, I have something that _works_, I am just curious to see
if there are benefits to other methods, or drawbacks to mine (i'm sure
my approach is naive):

workspace\projectname
workspace\projectname\build\classes (output dir for compiled classes)
workspace\projectname\deploy (holds my war file when I export from eclipse)
workspace\projectname\src\mypackage\ (no .java at this level)
workspace\projectname\src\mypackage\model\ (classes that know nothing
about tapestry)
workspace\projectname\src\mypackage\controller\ (classes for pages and
components)

workspace\projectname\src\META-INF\ (holds hivemind.xml and sessions.xml)

workspace\projectname\WebContent\css (css files)
workspace\projectname\images (jpgs)
workspace\projectname\META-INF (I think eclipse made this dir and
manifest.mf for me)

workspace\projectname\WEB-INF (all my .html, .page and .jwc files live
directly in WEB-INF, as well as projectname.application and web.xml)
workspace\projectname\lib (hold jars for jscookmenu, BIRT, etc)

workspace\projectname\reporting\BIRT (holds birt engine, jars, resources, etc)


When I export my project to a WAR, things in
workspace\projectname\build\classes
get put in
WEB-INF\classes

Please let me know what you think. I'm sure you guys have better
organized project structures.  For instance, do your Tapestry projects
look like this?
http://java.sun.com/blueprints/code/projectconventions.html

Daniel

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Restart tomcat from within tapestry

2006-09-21 Thread Peter Dawn

am using windows. so whats the location then. thanks.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Restart tomcat from within tapestry

2006-09-21 Thread Martin Strand

Perhaps you could simply let your listener method run a shell script?

String[] command = {"/etc/init.d/tomcat", "restart"};
Runtime.getRuntime().exec(command);

But, Tomcat restarting itself from a web ui? You should ask your client  
why he believes he needs this... :)


On Fri, 22 Sep 2006 00:51:58 +0200, Peter Dawn <[EMAIL PROTECTED]> wrote:


doesnt matter. the security risk is the responsibility of the client,
if they want it then I will implement it. I will make them aware of
the risks too.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Restart tomcat from within tapestry

2006-09-21 Thread Peter Dawn

doesnt matter. the security risk is the responsibility of the client,
if they want it then I will implement it. I will make them aware of
the risks too.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Restart tomcat from within tapestry

2006-09-21 Thread Daniel Jue

That would be nice to do if possible, although it would be a huge
security risk.  I would like it since at the moment I don't have
service restart privileges on some servers. =)

On a related note, I've been battling jar locking problems when hot
deploying my web app on Tomcat.  The AntiJARLocking and
AntiResourceLocking context flags are "not real solutions" to
paraphrase one Tomcat commiter.  So restarting the service is the
preferred option.  (The jars getting locked were js-cook-menu_1.21.jar
and derby.jar, not any Tapesty jars)



On 9/21/06, Peter Dawn <[EMAIL PROTECTED]> wrote:

guys,

i want the ability to restart tomcat from within my web app. i want to
provide a button, which the user clicks and it restarts tomcat.

can somebody tell me how should i go about this. i am using tap3.

thanks.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Doubt about implementing Ajax request

2006-09-21 Thread Jesse Kuhnert

Look for the parameters "updateComponents/async" in most of the Submit/Link
/ Form type components in the 4.1 documentation.

On 9/21/06, Daniel Castro <[EMAIL PROTECTED]> wrote:


Anyone?

I am using Ajax 4.1.  Need to do an ajax request to a class method so this
method will do a search on database and return the result to the
page.  How
to do it?

On 9/21/06, Daniel Castro <[EMAIL PROTECTED]> wrote:
>
> The problem is that the documentation was not clear, for me, and I dont
> know what Tapestry API to use to make an Ajax call...to invoke a method
of a
> class of mine and receive the response. and also how to make the binding
> between my button and the class method to call
>
>
> On 9/21/06, Jesse Kuhnert <[EMAIL PROTECTED]> wrote:
> >
> > Yes it does. Your post looked complicated enough that I figured you
> > already
> > knew that and ran into other issuesIt's fairly trivial to do what
> > you
> > want with all of the built in components if you read the documentation
> > provided for them.
> >
> > Just don't go trying to modify a table. No matter how great our ajax
> > stuff
> > is it can't make IE not suck. (though the new FilteringTable will help
> > when
> > it lands soon)
> >
> > On 9/21/06, Daniel Castro < [EMAIL PROTECTED]> wrote:
> > >
> > > Thanks :) I will look :)
> > > But I thought tapestry 4.1 would have some features for ajax submit
> > > already
> > > implemented.
> > >
> > > On 9/20/06, Karthik N <[EMAIL PROTECTED]> wrote:
> > > >
> > > > you should look at the excellent Tacos framework to help you on
> > this.
> > > It
> > > > makes Ajax with Tapestry a breeze, thanks to some great work done.
> > > >
> > > > http://tacos.sourceforge.net/
> > > >
> > > > in addition, if need be, you can look at Dojo and DWR to help you
> > with
> > > > Ajax.
> > > >
> > > > On 9/21/06, Daniel Castro <[EMAIL PROTECTED]> wrote:
> > > > >
> > > > > Guys, please help me, if possible.
> > > > >
> > > > > I have a page with a search form, and those form fields are used
> > as
> > > > > parameteres for a search query (SQL).
> > > > >
> > > > > There are two content holders, that are div tags with specified
> > ids,
> > > to
> > > > > hold
> > > > > the ajax return of the search and ajax return of the search
> > details.
> > > > > Those content holders are placed bellow the search form, on the
> > same
> > > > page.
> > > > >
> > > > > What is the search result and what is the search detail?
> > > > > Well, the search result is a 6 columns table sqlmodel component
> > (from
> > > > > contrib library) where the first column is the pk of the
database
> > > entry
> > > > > that
> > > > > is displayed and the last column is a button to invoke the
display
> > of
> > > > the
> > > > > details.
> > > > >
> > > > > The search detail is a table that displays less relevant
> > informations
> > > > > about
> > > > > one row of the search.
> > > > >
> > > > > so lets suppose that
> > > > > 1 - I have the form page with the submit button
> > > > > 2 - I have a tapestry tabel component that returns the search
> > result
> > > > >
> > > > > 3 - I have a class that returns a string containing the html
code
> > of
> > > > that
> > > > > detail table associated with a primary key.
> > > > > 4 - I have a button on the result table, for each row, that
passes
> > the
> > > > id
> > > > > of
> > > > > the row as atttribute or parameter
> > > > > 5 - I have the place holders identified (two div tags)
> > > > >
> > > > > How shoul I implement the ajax call for the search and the
detail?
> >
> > > > Please,
> > > > > step by step explanatuion if possble.
> > > > > My big problem is how to do this call, i tried some approaches
to
> > > solve
> > > > > this, but none was sucessful.
> > > > >
> > > > > Thanks everyone.
> > > > >
> > > > > --
> > > > > 
> > > > > We shall go on to the end.
> > > > > We shall fight in France
> > > > > We shall fightover the seas and oceans.
> > > > > We shall fight with growing confidence and growing strength in
the
> > > air.
> > > > > We shall defend our island whatever the cost may be
> > > > > We shall fight on beaches, we shall fight on the landing
grounds,
> > > > > We shall fight in the fields and in the streets,
> > > > > We shall fight on the hills.
> > > > > We shall never surrender.
> > > > > Winston Churchill
> > > > >
> > > > >
> > > >
> > > >
> > > > --
> > > > Thanks, Karthik
> > > >
> > > >
> > >
> > >
> > > --
> > > 
> > > We shall go on to the end.
> > > We shall fight in France
> > > We shall fightover the seas and oceans.
> > > We shall fight with growing confidence and growing strength in the
> > air.
> > > We shall defend our island whatever the cost may be
> > > We shall fight on beaches, we shall fight on the landing grounds,
> > > We shall fight in the fields and in the streets,
> > > We shall fight on the hills.
> > > We shall never surrender.
> > > Winston Churchill
> > >
> > >
> >
> >
> > --
> > Jesse Kuhnert
> > Tapestry/Dojo/(and a dash of TestNG), team member

Restart tomcat from within tapestry

2006-09-21 Thread Peter Dawn

guys,

i want the ability to restart tomcat from within my web app. i want to
provide a button, which the user clicks and it restarts tomcat.

can somebody tell me how should i go about this. i am using tap3.

thanks.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: application namespace message catalog question

2006-09-21 Thread Martin Strand
I have no idea what could be wrong, nested components work fine with my  
global message catalog... Sorry. :(


On Thu, 21 Sep 2006 22:39:45 +0200, Scott Jarvi <[EMAIL PROTECTED]>  
wrote:


Yes, we have an .application and .properties in the same  
directory.

This works for us as well, for all of our pages that share resource keys.
In this specific case, my component is referenced in the page, but nested
inside our custom border component - is it the nested component that  
could

be causing the problem?



On 9/21/06, Martin Strand <[EMAIL PROTECTED]> wrote:


It should be working, it does for me. Did you put it in the same dir as
your .application file?
YourApp.application
YourApp_en.properties

On Thu, 21 Sep 2006 21:41:00 +0200, Scott Jarvi <[EMAIL PROTECTED]>
wrote:

> Hi,
>
> I have a component that makes use of localized messages that may be
> shared
> by other components and pages.  Because of this, I've put the keys in  
my

> application-level message catalog.  For some reason, the keys are not
> found
> when the component is rendered on my page.  This seems like it should  
be

> supported based on the documentation, so I must be missing something
> simple.  Any ideas??
>
> Regards,
> Scott

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]








-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: application namespace message catalog question

2006-09-21 Thread Scott Jarvi

Yes, we have an .application and .properties in the same directory.
This works for us as well, for all of our pages that share resource keys.
In this specific case, my component is referenced in the page, but nested
inside our custom border component - is it the nested component that could
be causing the problem?



On 9/21/06, Martin Strand <[EMAIL PROTECTED]> wrote:


It should be working, it does for me. Did you put it in the same dir as
your .application file?
YourApp.application
YourApp_en.properties

On Thu, 21 Sep 2006 21:41:00 +0200, Scott Jarvi <[EMAIL PROTECTED]>
wrote:

> Hi,
>
> I have a component that makes use of localized messages that may be
> shared
> by other components and pages.  Because of this, I've put the keys in my
> application-level message catalog.  For some reason, the keys are not
> found
> when the component is rendered on my page.  This seems like it should be
> supported based on the documentation, so I must be missing something
> simple.  Any ideas??
>
> Regards,
> Scott

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: Alternate way to @EventListener with java 1.4

2006-09-21 Thread Denis Souza
I don't know if you can use it in Tap 4.1 but tacos 4 has a
"AjaxEventSubmit" component that does something similar. I'm not sure it
does everything @EventListener does, but maybe it's enough for what you
need.

-Original Message-
From: Numa Schmeder [mailto:[EMAIL PROTECTED] 
Sent: quinta-feira, 21 de setembro de 2006 11:39
To: Tapestry users
Subject: Alternate way to @EventListener with java 1.4

Hello,

Is there a way if you are using java 1.4 to have a similar  
functionality to @EventListener.
I am developing a new application and i would like to go with tap 4.1  
but this application will run on java 1.4 so i can't use annotations,  
but i would really like to have a similar functionality to  
@EventListener.

Thanks

Numa

http://www.le-voyage.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: How do I intercept an org.apache.hivemind.ApplicationRuntimeException?

2006-09-21 Thread Ben Dotte
This thread might be a little help:
http://article.gmane.org/gmane.comp.java.tapestry.user/29684

I've never found a way to override the "ugly" error page, I believe the
exception is thrown by commons fileupload, not Tapestry. So I just set
MultipartDecoderImpl's maxSize to "-1" and validate the filesize with a
validator.

HTH

Ben

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Thursday, September 21, 2006 12:52 PM
To: users@tapestry.apache.org
Subject: How do I intercept an
org.apache.hivemind.ApplicationRuntimeException?

I have a page that allows for file uploads, up to 10MB.

The limit is enforced in my hivemodule.xml with this snippet:



  


It works perfectly...if you upload a file larger than 10MB, you get a
big "ugly" error page (pasted below).  We catch all other exceptions
with a configuration line in the .application file:


But that isn't getting triggered on these > 10MB upload errors.

Thoughts? And Thanks,
Tom


Here's the big ugly error page:
---

HTTP Status 500 -

type Exception report

message

description The server encountered an internal error () that prevented
it from fulfilling this request.

exception

org.apache.hivemind.ApplicationRuntimeException: Unable to decode
multipart encoded request: the request was rejected because its size
(23940489) exceeds the configured maximum (10485760)

org.apache.tapestry.multipart.MultipartDecoderImpl.decode(MultipartDecod
erImpl.java:56)

$ServletMultipartDecoder_10dd1546644.decode($ServletMultipartDecoder_10d
d1546644.java)

$ServletMultipartDecoder_10dd1546645.decode($ServletMultipartDecoder_10d
d1546645.java)
org.apache.tapestry.multipart.MultipartDetc ad naseum

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: application namespace message catalog question

2006-09-21 Thread Martin Strand
It should be working, it does for me. Did you put it in the same dir as  
your .application file?

YourApp.application
YourApp_en.properties

On Thu, 21 Sep 2006 21:41:00 +0200, Scott Jarvi <[EMAIL PROTECTED]>  
wrote:



Hi,

I have a component that makes use of localized messages that may be  
shared

by other components and pages.  Because of this, I've put the keys in my
application-level message catalog.  For some reason, the keys are not  
found

when the component is rendered on my page.  This seems like it should be
supported based on the documentation, so I must be missing something
simple.  Any ideas??

Regards,
Scott


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Doubt about implementing Ajax request

2006-09-21 Thread Daniel Castro

Anyone?

I am using Ajax 4.1.  Need to do an ajax request to a class method so this
method will do a search on database and return the result to the page.  How
to do it?

On 9/21/06, Daniel Castro <[EMAIL PROTECTED]> wrote:


The problem is that the documentation was not clear, for me, and I dont
know what Tapestry API to use to make an Ajax call...to invoke a method of a
class of mine and receive the response. and also how to make the binding
between my button and the class method to call


On 9/21/06, Jesse Kuhnert <[EMAIL PROTECTED]> wrote:
>
> Yes it does. Your post looked complicated enough that I figured you
> already
> knew that and ran into other issuesIt's fairly trivial to do what
> you
> want with all of the built in components if you read the documentation
> provided for them.
>
> Just don't go trying to modify a table. No matter how great our ajax
> stuff
> is it can't make IE not suck. (though the new FilteringTable will help
> when
> it lands soon)
>
> On 9/21/06, Daniel Castro < [EMAIL PROTECTED]> wrote:
> >
> > Thanks :) I will look :)
> > But I thought tapestry 4.1 would have some features for ajax submit
> > already
> > implemented.
> >
> > On 9/20/06, Karthik N <[EMAIL PROTECTED]> wrote:
> > >
> > > you should look at the excellent Tacos framework to help you on
> this.
> > It
> > > makes Ajax with Tapestry a breeze, thanks to some great work done.
> > >
> > > http://tacos.sourceforge.net/
> > >
> > > in addition, if need be, you can look at Dojo and DWR to help you
> with
> > > Ajax.
> > >
> > > On 9/21/06, Daniel Castro <[EMAIL PROTECTED]> wrote:
> > > >
> > > > Guys, please help me, if possible.
> > > >
> > > > I have a page with a search form, and those form fields are used
> as
> > > > parameteres for a search query (SQL).
> > > >
> > > > There are two content holders, that are div tags with specified
> ids,
> > to
> > > > hold
> > > > the ajax return of the search and ajax return of the search
> details.
> > > > Those content holders are placed bellow the search form, on the
> same
> > > page.
> > > >
> > > > What is the search result and what is the search detail?
> > > > Well, the search result is a 6 columns table sqlmodel component
> (from
> > > > contrib library) where the first column is the pk of the database
> > entry
> > > > that
> > > > is displayed and the last column is a button to invoke the display
> of
> > > the
> > > > details.
> > > >
> > > > The search detail is a table that displays less relevant
> informations
> > > > about
> > > > one row of the search.
> > > >
> > > > so lets suppose that
> > > > 1 - I have the form page with the submit button
> > > > 2 - I have a tapestry tabel component that returns the search
> result
> > > >
> > > > 3 - I have a class that returns a string containing the html code
> of
> > > that
> > > > detail table associated with a primary key.
> > > > 4 - I have a button on the result table, for each row, that passes
> the
> > > id
> > > > of
> > > > the row as atttribute or parameter
> > > > 5 - I have the place holders identified (two div tags)
> > > >
> > > > How shoul I implement the ajax call for the search and the detail?
>
> > > Please,
> > > > step by step explanatuion if possble.
> > > > My big problem is how to do this call, i tried some approaches to
> > solve
> > > > this, but none was sucessful.
> > > >
> > > > Thanks everyone.
> > > >
> > > > --
> > > > 
> > > > We shall go on to the end.
> > > > We shall fight in France
> > > > We shall fightover the seas and oceans.
> > > > We shall fight with growing confidence and growing strength in the
> > air.
> > > > We shall defend our island whatever the cost may be
> > > > We shall fight on beaches, we shall fight on the landing grounds,
> > > > We shall fight in the fields and in the streets,
> > > > We shall fight on the hills.
> > > > We shall never surrender.
> > > > Winston Churchill
> > > >
> > > >
> > >
> > >
> > > --
> > > Thanks, Karthik
> > >
> > >
> >
> >
> > --
> > 
> > We shall go on to the end.
> > We shall fight in France
> > We shall fightover the seas and oceans.
> > We shall fight with growing confidence and growing strength in the
> air.
> > We shall defend our island whatever the cost may be
> > We shall fight on beaches, we shall fight on the landing grounds,
> > We shall fight in the fields and in the streets,
> > We shall fight on the hills.
> > We shall never surrender.
> > Winston Churchill
> >
> >
>
>
> --
> Jesse Kuhnert
> Tapestry/Dojo/(and a dash of TestNG), team member/developer
>
> Open source based consulting work centered around
> dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com
>
>


--

We shall go on to the end.
We shall fight in France
We shall fightover the seas and oceans.
We shall fight with growing confidence and growing strength in the air.
We shall defend our island whatever the cost may be
We shall fight on beaches, we shall fight on the landing grounds,
We shall fight in the fields and in th

Re: Is breadcrumbs component hard in Tapestry?

2006-09-21 Thread Vjeran Marcinko


- Original Message - 
From: "Robert Zeigler" <[EMAIL PROTECTED]>

To: "Tapestry users" 
Sent: Thursday, September 21, 2006 9:10 PM
Subject: Re: Is breadcrumbs component hard in Tapestry?


I haven't made a breadcrumbs component in tapestry. But I have a comment on 
implementation:
If it's possible that some (or all) pages in the trail need parameters (as 
you mentioned), don't use page links or Direct Links at all; your pages 
(at least all of the ones that might end up as a "crumb") probably ought 
to implement the IExternalPage (or is it IExternal? I always forget...) 
interface, do the setup based on the objectid (or whatever setup) in the 
activateExternalPage method, and then your component can (should) use 
ExternalLinks.  This will keep your links much nicer, and the page setup 
logic contained within the appropriate page.


Thanx Robert.

I also thought that it would maybe work with IExternal stuff because these 
seem most similar to traditional action-based aproach. Listener method would 
be a little uglier though.


-Vjeran


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



application namespace message catalog question

2006-09-21 Thread Scott Jarvi

Hi,

I have a component that makes use of localized messages that may be shared
by other components and pages.  Because of this, I've put the keys in my
application-level message catalog.  For some reason, the keys are not found
when the component is rendered on my page.  This seems like it should be
supported based on the documentation, so I must be missing something
simple.  Any ideas??

Regards,
Scott


RE: Dynamic Sections on a Page

2006-09-21 Thread Michael Grundvig
Im sorry, I don't think I explained that well at all (I was barely awake
at the time). What I need is along the lines of a dynamic include in a
JSP. Where the included JSP still executes as always but you are able to
specify the include path itself as a variable. That's what I'm looking to
accomplish. If this can be done with Block and RenderBlock, can you
provide more details? Thanks!

Michael


-Original Message-
From: "Firas Adiler" <[EMAIL PROTECTED]>
Sent: Thu, September 21, 2006 12:25 pm
To: "Tapestry users" 
Subject: RE: Dynamic Sections on a Page

Hi,

I think these components are well suited for this kind of job:

http://tapestry.apache.org/tapestry4/tapestry/ComponentReference/RenderBlock
.html
http://tapestry.apache.org/tapestry4/tapestry/ComponentReference/Block.html





-Original Message-
From: Mike Grundvig [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 21, 2006 3:41 PM
To: Tapestry users
Subject: Dynamic Sections on a Page

Hi all; first off, I just wanted to express my thanks to the devs and
community for making Tapestry. It's a real piece of art. Thanks!

I'm working on a site that has an admin system to store advertisments. These
advertisements are small HTML blocks that they want inserted into specific
places inside of a page. The entire site is broken into sections and the ads
are tied to all the pages in a section. I know I can make a custom component
and inject my ad service into it and then use that to load the files from
the file system and dump the ad HTML right into the pages but that feels
very clumsy. I want the ad HTML to be valid tapestry pages in their own
right so they can take advantage of all the capabilities of tapestry.

Basically, Id like a component that looks something like this:

Ad 1 goes here

And that would go on every page with a different section id for all
locations. Then it would do this internally (psuedo code, obviously):

// the url for this ad might be "/ads/blah.html" (yes, I have friendly urls
working)
Template template = getAdService().getTemplate(adId, sectionId);
template.render();

How can I get a page from the tapestry engine via the name or path or some
such in a way that I can dump it into the page? Thanks in advance for any
advice!

Michael




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Is breadcrumbs component hard in Tapestry?

2006-09-21 Thread Robert Zeigler
I haven't made a breadcrumbs component in tapestry. But I have a comment 
on implementation:
If it's possible that some (or all) pages in the trail need parameters 
(as you mentioned), don't use page links or Direct Links at all; your 
pages (at least all of the ones that might end up as a "crumb") probably 
ought to implement the IExternalPage (or is it IExternal? I always 
forget...) interface, do the setup based on the objectid (or whatever 
setup) in the activateExternalPage method, and then your component can 
(should) use ExternalLinks.  This will keep your links much nicer, and 
the page setup logic contained within the appropriate page.


Vjeran Marcinko wrote:


Hello all.

I tried to develop my breadcrumbs component, but it seems that it is a 
bit harder than expected to do it in component framework.


Anyway, has anyone developed the same and is willing to share? 
IMPORTANT NOTE: this breadcrumb component should be dynamic in nature, 
not using only PageLinks to render links, but also DirectLinks (or 
whatever) to be able to pass some additional argument required for 
displaying some breadcrumb page. Typical case is when some breadcrumb 
link is leading to some EntityHome page of some db entity that 
requires entity ID to be displayed.


Regards,
Vjeran


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: How to obtain the servlet instance?

2006-09-21 Thread Shing Hing Man
If you are after the HttpServletRequest, you might
like to try the following.

@InjectObject("service:tapestry.globals.HttpServletRequest")
public abstract HttpServletRequest
getServletRequest();

Shing

--- Manuel Sugawara  wrote:

> Hi all, I would like to obtain the servlet instance
> from within my
> pages in order to call the HttpSevlet methods for
> logging. My first
> cut was injecting it using something like:
> 
>
>
@InjectObject("service:tapestry.globals.HttpServlet")
> public abstract HttpServlet getHttpServlet();   
> 
> 
> To my surprise this didn't work :-(, Is there any
> way to get the
> servlet instance?, if not, How can I write to the
> servlet log from
> within my pages?.
> 
> Regards,
> Manuel.
> 
> 
>
-
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> 
> 


Home page :
  http://uk.geocities.com/matmsh/index.html



___ 
Inbox full of spam? Get leading spam protection and 1GB storage with All New 
Yahoo! Mail. http://uk.docs.yahoo.com/nowyoucan.html

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



How do I intercept an org.apache.hivemind.ApplicationRuntimeException?

2006-09-21 Thread Thomas.Vaughan
I have a page that allows for file uploads, up to 10MB.

The limit is enforced in my hivemodule.xml with this snippet:



  


It works perfectly...if you upload a file larger than 10MB, you get a
big "ugly" error page (pasted below).  We catch all other exceptions
with a configuration line in the .application file:


But that isn't getting triggered on these > 10MB upload errors.

Thoughts? And Thanks,
Tom


Here's the big ugly error page:
---

HTTP Status 500 -

type Exception report

message

description The server encountered an internal error () that prevented
it from fulfilling this request.

exception

org.apache.hivemind.ApplicationRuntimeException: Unable to decode
multipart encoded request: the request was rejected because its size
(23940489) exceeds the configured maximum (10485760)

org.apache.tapestry.multipart.MultipartDecoderImpl.decode(MultipartDecod
erImpl.java:56)

$ServletMultipartDecoder_10dd1546644.decode($ServletMultipartDecoder_10d
d1546644.java)

$ServletMultipartDecoder_10dd1546645.decode($ServletMultipartDecoder_10d
d1546645.java)
org.apache.tapestry.multipart.MultipartDetc ad naseum

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: EventListener can update a For component ?

2006-09-21 Thread Jesse Kuhnert

Make sure that your "requestorsLoop" is outputting an actual html element on
render. If you can't view source of a rendered page and find an existing
html element then there is nothing to "update". I think using the For
component you have to specify element="div || span || whatever " to get it
to output the content.

On 9/21/06, Roberto Ramírez Vique <[EMAIL PROTECTED]> wrote:


Hi everybody,

I'm an starter in Tapestry 4.1, using tomcat 5.5 and jdk 1.5

I want to have a link (a plus image :P) that adds a new element to the for
loop. I tried this:

@EventListener(elements="addLink", events="onclick",
submitForm="userForm", async=true)
public void addNewRequester(IRequestCycle cycle){
this.getLoanAdvice().getRequesters().add(new
PersonEconomicEvaluation());

cycle.getResponseBuilder().updateComponent("requestersLoop");
}

The html is this:








Obviously, "requesterLoop" is a loop over the
getLoanAdvice().getRequesters() ... the method 'addNewRequester' is supose
to add a new item in the for loop. The serverside is called, but the
client
side doens't update correctly, eventhough I call the '
cycle.getResponseBuilder().updateComponent("requestersLoop");' method... I
tried updating directly the entire form, but doesn't work.

My first question is, is it possible ?

And the second one is, can any of you see what I'm missing?

Thanks in advance,
--
Robert Ramírez Vique
Computer Science Engineer





--
Jesse Kuhnert
Tapestry/Dojo/(and a dash of TestNG), team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: EventListener can update a For component ?

2006-09-21 Thread Roberto Ramírez Vique

Problem solved, sorry, it was an stupid problem ... just a duplicated id for
the addLink element.

Anyway now this part works.

On 9/21/06, Roberto Ramírez Vique <[EMAIL PROTECTED]> wrote:


Hi everybody,

I'm an starter in Tapestry 4.1, using tomcat 5.5 and jdk 1.5

I want to have a link (a plus image :P) that adds a new element to the for
loop. I tried this:

@EventListener(elements="addLink", events="onclick",
submitForm="userForm", async=true)
public void addNewRequester(IRequestCycle cycle){
this.getLoanAdvice().getRequesters().add(new
PersonEconomicEvaluation());

cycle.getResponseBuilder().updateComponent("requestersLoop");
}

The html is this:








Obviously, "requesterLoop" is a loop over the
getLoanAdvice().getRequesters() ... the method 'addNewRequester' is supose
to add a new item in the for loop. The serverside is called, but the client
side doens't update correctly, eventhough I call the '
cycle.getResponseBuilder().updateComponent("requestersLoop");' method... I
tried updating directly the entire form, but doesn't work.

My first question is, is it possible ?

And the second one is, can any of you see what I'm missing?

Thanks in advance,
--
Robert Ramírez Vique
Computer Science Engineer





--
Robert Ramírez Vique
Computer Science Engineer


Re: BeanForm and no setter method for persistence id

2006-09-21 Thread D&J Gredler

Are you listing the properties explicitly, i.e.
properties="name,description"? If that's the case, I don't see how the
BeanForm knows anything at all about your ID field. And if there's not even
a setId( ) method, there's no way at all for BeanForm to modify the property
(it doesn't modify fields directly). Is your Group object marked persistent
in the page specification? This sounds like a problem somewhere else...

Keep me updated,

Daniel


On 9/21/06, Claus Myglegaard Vagner <[EMAIL PROTECTED]> wrote:


Hi,

Is it possible to use the BeanForm component
(http://beanform.sourceforge.net/) for updating a pojo with no setter
method for a persistence id?

For example I have a Group object with properties id, name, description.
In the form only name and description is shown. I don't want to show the
id and I don't want to have a setId(id) method on the pojo. This should
be controlled by hibernate (with field access) completely.

When there is no setter method for id - BeanForm is returning a Group
object with a null "value" for id. This means that what should have been
an update in the database becomes an insert since hibernate thinks that
it is an not-persisted object (no id).

Why cant the BeanForm component just update the fields in action (in the
form) for the pojo e.g. just call setName and setDecription and leave
the id intact?

Regards Claus


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: Dynamic Sections on a Page

2006-09-21 Thread Firas Adiler
Hi,

I think these components are well suited for this kind of job:

http://tapestry.apache.org/tapestry4/tapestry/ComponentReference/RenderBlock
.html
http://tapestry.apache.org/tapestry4/tapestry/ComponentReference/Block.html

 

 

-Original Message-
From: Mike Grundvig [mailto:[EMAIL PROTECTED] 
Sent: Thursday, September 21, 2006 3:41 PM
To: Tapestry users
Subject: Dynamic Sections on a Page

Hi all; first off, I just wanted to express my thanks to the devs and
community for making Tapestry. It's a real piece of art. Thanks!

I'm working on a site that has an admin system to store advertisments. These
advertisements are small HTML blocks that they want inserted into specific
places inside of a page. The entire site is broken into sections and the ads
are tied to all the pages in a section. I know I can make a custom component
and inject my ad service into it and then use that to load the files from
the file system and dump the ad HTML right into the pages but that feels
very clumsy. I want the ad HTML to be valid tapestry pages in their own
right so they can take advantage of all the capabilities of tapestry.

Basically, Id like a component that looks something like this:

Ad 1 goes here

And that would go on every page with a different section id for all
locations. Then it would do this internally (psuedo code, obviously):

// the url for this ad might be "/ads/blah.html" (yes, I have friendly urls
working)
Template template = getAdService().getTemplate(adId, sectionId);
template.render();

How can I get a page from the tapestry engine via the name or path or some
such in a way that I can dump it into the page? Thanks in advance for any
advice!

Michael 




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: tapestry-acegi form based login

2006-09-21 Thread Jonathan Barker

My approach predates tapestry-acegi, but I'm sure it could be adapted.

I use a bit of a hybrid approach, where the authentication part is handled
as described in the EWDT e-book and all of my protected pages extend a
BaseProtectedPage class. My Login page has a UserValidator ASO injected,
which in turn has an Acegi AuthenticationManager wired in by a
UserValidatorFactory.

My UserValidator ASO has validateUser(String username, String password)
method that returns a UserProfile object (that implements Acegi's
UserDetails).  It invokes the AutheticationManager's authenticate method and
stores the Authentication object into the SecurityContext.  This replaces
the pure-Acegi login form handling and allows me to use the EWDT style.

There is also a convenience method checkPermission(String ifAnyGranted,
String ifAllGranted, String ifNotGranted) that behaves like the Acegi's JSP
taglib Authorize tag so I can make fine-grained decisions within a page.


Jonathan


> -Original Message-
> From: news [mailto:[EMAIL PROTECTED] On Behalf Of Jesper Zedlitz
> Sent: Thursday, September 21, 2006 8:30 AM
> To: users@tapestry.apache.org
> Subject: tapestry-acegi form based login
> 
> Is it possible to use a html form for login with tapestry-acegi instead of
> HTTP basic authentication?
> 
> I would like to write a third part for my tutorial
> http://wiki.apache.org/tapestry/AcegiSpringJava5 about that topic.
> 
> Jesper
> 
> --
>  Jesper Zedlitz   E-Mail   : [EMAIL PROTECTED]
>   Homepage : http://www.zedlitz.de
>   ICQ# : 23890711
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



How to obtain the servlet instance?

2006-09-21 Thread Manuel Sugawara
Hi all, I would like to obtain the servlet instance from within my
pages in order to call the HttpSevlet methods for logging. My first
cut was injecting it using something like:

@InjectObject("service:tapestry.globals.HttpServlet")
public abstract HttpServlet getHttpServlet();

To my surprise this didn't work :-(, Is there any way to get the
servlet instance?, if not, How can I write to the servlet log from
within my pages?.

Regards,
Manuel.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Alternate way to @EventListener with java 1.4

2006-09-21 Thread Numa Schmeder

Hello,

Is there a way if you are using java 1.4 to have a similar  
functionality to @EventListener.
I am developing a new application and i would like to go with tap 4.1  
but this application will run on java 1.4 so i can't use annotations,  
but i would really like to have a similar functionality to  
@EventListener.


Thanks

Numa

http://www.le-voyage.com

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: tapestry-acegi form based login

2006-09-21 Thread Robin Ericsson

On 9/21/06, Jesper Zedlitz <[EMAIL PROTECTED]> wrote:

Is it possible to use a html form for login with tapestry-acegi instead of
HTTP basic authentication?


I'd like to know that too.


I would like to write a third part for my tutorial
http://wiki.apache.org/tapestry/AcegiSpringJava5 about that topic.


Nice tutorial.

I can answer your other wiki question about realm name.

   
   
   

--
   regards,
   Robin

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: OT - [Tapestry-Users] - prefix in mail subject?

2006-09-21 Thread Martin Strand
Opera categorizes lists automatically. :)
If you use another client perhaps you can use these headers to filter out list 
messages:

> Mailing-List: contact [EMAIL PROTECTED]; run by ezmlm
> Precedence: bulk
> List-Help: 
> List-Unsubscribe: 
> List-Post: 
> List-Id: 

E.g. everything with "List-Id: " --> deliver to your 
your tapestry folder

On Thu, 21 Sep 2006 16:00:30 +0200, Karthik N <[EMAIL PROTECTED]> wrote:

> Is there any way to set up the mails that go out prefixed with
> [Tapestry-Users]  or something such?  Just helps categorization of mails an
> easier tasks, visually.
>
> Thanks, Karthik
>



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Troubles rendering CSS with Tapestry 4.0.2

2006-09-21 Thread Andreas Andreou

Servers do not serve content out of the WEB-INF folder.

I'd move the css file in context/css/menu.css
then define

and for previewing the templates directly in browsers








Peter J. Siegel wrote:

For some days I've spent hours and hours increating a page that is rendered 
with the attached CSS. Aftertravelling round in the forum several tutorials and 
Google, I reallydon't know why the most described solution doesn't work for me. 
I'msure I overlook an important detail. Now I'm asking you professionalsout 
there in the world for the golden hint.

The test app should load only one page that shows a navigation menu usingCSS. If I load 
this HTML page directly into the browser, it is shown correctly. If I call the page 
within the Tapestry application, the CSS styles are not shown. It seems like there 
wouldn't be any CSS file. The page is shown like written with  "naked" HTML.


Could anyone have a short look and *please* post a tip or a solution ?

Thank you very much.


Peter


-

The .application file:

[code]


http://jakarta.apache.org/tapestry/dtd/Tapestry_4_0.dtd";>







[/code]

-

The menu's .html file:

[code]







  Back  
  Forward  
  Reload  




[/code]

-

The menu's .page file:

[code] 



http://jakarta.apache.org/tapestry/dtd/Tapestry_4_0.dtd";>





[/code]

The menu's CSS file:

[code]

#navigation  {
font-family: Arial, Helvetica, sans-serif;
font-size: .9em;
}

#navigation ul {
list-style: none;
margin: 0;
padding: 0;
padding-top: 4px;
}

#navigation li {
display: inline;
}

#navigation a:link, #navigation a:visited {
padding: 3px 10px 2px 10px;
color: #FF;
background-color: #B51032;
text-decoration: none;
border: 1px solid #711515;
}

#navigation a:hover {
color: #FF;
background-color: #711515;
}	  


[/code]


-

The menu's .java  page:

[code]

package de.peter_siegel.tapestry.pages;

import org.apache.tapestry.html.BasePage;

public class Menu extends BasePage {
}

[/code]

-

The rendered output HTML code in the browser:

[code]

http://www.w3.org/TR/html4/loose.dtd";>







http://localhost:8080/TapestryHelloWorld/"/>
Navigation






  Back  
  Forward  
  Reload  






[/code]




  


--
Andreas Andreou - [EMAIL PROTECTED] - http://andyhot.di.uoa.gr
Tapestry / Tacos developer
Open Source / J2EE Consulting


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: OT - [Tapestry-Users] - prefix in mail subject?

2006-09-21 Thread Karthik N

Sometimes visual scanning of the Email subject seems to help me a lot.

But maybe it's just me ...

On 9/21/06, James Carman <[EMAIL PROTECTED]> wrote:


Can't you categorize based on the recipient?  Gmail offers that as an
option
when filtering.

-Original Message-
From: Karthik N [mailto:[EMAIL PROTECTED]
Sent: Thursday, September 21, 2006 10:01 AM
To: Tapestry users
Subject: OT - [Tapestry-Users] - prefix in mail subject?

Is there any way to set up the mails that go out prefixed with
[Tapestry-Users]  or something such?  Just helps categorization of mails
an
easier tasks, visually.

Thanks, Karthik



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Thanks, Karthik


RE: OT - [Tapestry-Users] - prefix in mail subject?

2006-09-21 Thread James Carman
Can't you categorize based on the recipient?  Gmail offers that as an option
when filtering.

-Original Message-
From: Karthik N [mailto:[EMAIL PROTECTED] 
Sent: Thursday, September 21, 2006 10:01 AM
To: Tapestry users
Subject: OT - [Tapestry-Users] - prefix in mail subject?

Is there any way to set up the mails that go out prefixed with
[Tapestry-Users]  or something such?  Just helps categorization of mails an
easier tasks, visually.

Thanks, Karthik



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



OT - [Tapestry-Users] - prefix in mail subject?

2006-09-21 Thread Karthik N

Is there any way to set up the mails that go out prefixed with
[Tapestry-Users]  or something such?  Just helps categorization of mails an
easier tasks, visually.

Thanks, Karthik


Troubles rendering CSS with Tapestry 4.0.2

2006-09-21 Thread Peter J. Siegel
For some days I've spent hours and hours increating a page that is rendered 
with the attached CSS. Aftertravelling round in the forum several tutorials and 
Google, I reallydon't know why the most described solution doesn't work for me. 
I'msure I overlook an important detail. Now I'm asking you professionalsout 
there in the world for the golden hint.

The test app should load only one page that shows a navigation menu usingCSS. 
If I load this HTML page directly into the browser, it is shown correctly. If I 
call the page within the Tapestry application, the CSS styles are not shown. It 
seems like there wouldn't be any CSS file. The page is shown like written with  
"naked" HTML.


Could anyone have a short look and *please* post a tip or a solution ?

Thank you very much.


Peter


-

The .application file:

[code]


http://jakarta.apache.org/tapestry/dtd/Tapestry_4_0.dtd";>







[/code]

-

The menu's .html file:

[code]







  Back  
  Forward  
  Reload  




[/code]

-

The menu's .page file:

[code] 


http://jakarta.apache.org/tapestry/dtd/Tapestry_4_0.dtd";>





[/code]

The menu's CSS file:

[code]

#navigation  {
font-family: Arial, Helvetica, sans-serif;
font-size: .9em;
}

#navigation ul {
list-style: none;
margin: 0;
padding: 0;
padding-top: 4px;
}

#navigation li {
display: inline;
}

#navigation a:link, #navigation a:visited {
padding: 3px 10px 2px 10px;
color: #FF;
background-color: #B51032;
text-decoration: none;
border: 1px solid #711515;
}

#navigation a:hover {
color: #FF;
background-color: #711515;
} 

[/code]


-

The menu's .java  page:

[code]

package de.peter_siegel.tapestry.pages;

import org.apache.tapestry.html.BasePage;

public class Menu extends BasePage {
}

[/code]

-

The rendered output HTML code in the browser:

[code]

http://www.w3.org/TR/html4/loose.dtd";>







http://localhost:8080/TapestryHelloWorld/"/>
Navigation






  Back  
  Forward  
  Reload  






[/code]





Dynamic Sections on a Page

2006-09-21 Thread Mike Grundvig
Hi all; first off, I just wanted to express my thanks to the devs and 
community for making Tapestry. It's a real piece of art. Thanks!


I'm working on a site that has an admin system to store advertisments. These 
advertisements are small HTML blocks that they want inserted into specific 
places inside of a page. The entire site is broken into sections and the ads 
are tied to all the pages in a section. I know I can make a custom component 
and inject my ad service into it and then use that to load the files from 
the file system and dump the ad HTML right into the pages but that feels 
very clumsy. I want the ad HTML to be valid tapestry pages in their own 
right so they can take advantage of all the capabilities of tapestry.


Basically, Id like a component that looks something like this:

Ad 1 goes here

And that would go on every page with a different section id for all 
locations. Then it would do this internally (psuedo code, obviously):


// the url for this ad might be "/ads/blah.html" (yes, I have friendly urls 
working)

Template template = getAdService().getTemplate(adId, sectionId);
template.render();

How can I get a page from the tapestry engine via the name or path or some 
such in a way that I can dump it into the page? Thanks in advance for any 
advice!


Michael 




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



BeanForm and no setter method for persistence id

2006-09-21 Thread Claus Myglegaard Vagner

Hi,

Is it possible to use the BeanForm component 
(http://beanform.sourceforge.net/) for updating a pojo with no setter 
method for a persistence id?


For example I have a Group object with properties id, name, description. 
In the form only name and description is shown. I don't want to show the 
id and I don't want to have a setId(id) method on the pojo. This should 
be controlled by hibernate (with field access) completely.


When there is no setter method for id - BeanForm is returning a Group 
object with a null "value" for id. This means that what should have been 
an update in the database becomes an insert since hibernate thinks that 
it is an not-persisted object (no id).


Why cant the BeanForm component just update the fields in action (in the 
form) for the pojo e.g. just call setName and setDecription and leave 
the id intact?


Regards Claus


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



tapestry-acegi form based login

2006-09-21 Thread Jesper Zedlitz
Is it possible to use a html form for login with tapestry-acegi instead of
HTTP basic authentication?

I would like to write a third part for my tutorial
http://wiki.apache.org/tapestry/AcegiSpringJava5 about that topic.

Jesper

-- 
 Jesper Zedlitz   E-Mail   : [EMAIL PROTECTED]
  Homepage : http://www.zedlitz.de
  ICQ# : 23890711


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Doubt about implementing Ajax request

2006-09-21 Thread Daniel Castro

The problem is that the documentation was not clear, for me, and I dont know
what Tapestry API to use to make an Ajax call...to invoke a method of a
class of mine and receive the response. and also how to make the binding
between my button and the class method to call


On 9/21/06, Jesse Kuhnert <[EMAIL PROTECTED]> wrote:


Yes it does. Your post looked complicated enough that I figured you
already
knew that and ran into other issuesIt's fairly trivial to do what you
want with all of the built in components if you read the documentation
provided for them.

Just don't go trying to modify a table. No matter how great our ajax stuff
is it can't make IE not suck. (though the new FilteringTable will help
when
it lands soon)

On 9/21/06, Daniel Castro <[EMAIL PROTECTED]> wrote:
>
> Thanks :) I will look :)
> But I thought tapestry 4.1 would have some features for ajax submit
> already
> implemented.
>
> On 9/20/06, Karthik N <[EMAIL PROTECTED]> wrote:
> >
> > you should look at the excellent Tacos framework to help you on this.
> It
> > makes Ajax with Tapestry a breeze, thanks to some great work done.
> >
> > http://tacos.sourceforge.net/
> >
> > in addition, if need be, you can look at Dojo and DWR to help you with
> > Ajax.
> >
> > On 9/21/06, Daniel Castro <[EMAIL PROTECTED]> wrote:
> > >
> > > Guys, please help me, if possible.
> > >
> > > I have a page with a search form, and those form fields are used as
> > > parameteres for a search query (SQL).
> > >
> > > There are two content holders, that are div tags with specified ids,
> to
> > > hold
> > > the ajax return of the search and ajax return of the search details.
> > > Those content holders are placed bellow the search form, on the same
> > page.
> > >
> > > What is the search result and what is the search detail?
> > > Well, the search result is a 6 columns table sqlmodel component
(from
> > > contrib library) where the first column is the pk of the database
> entry
> > > that
> > > is displayed and the last column is a button to invoke the display
of
> > the
> > > details.
> > >
> > > The search detail is a table that displays less relevant
informations
> > > about
> > > one row of the search.
> > >
> > > so lets suppose that
> > > 1 - I have the form page with the submit button
> > > 2 - I have a tapestry tabel component that returns the search result
> > >
> > > 3 - I have a class that returns a string containing the html code of
> > that
> > > detail table associated with a primary key.
> > > 4 - I have a button on the result table, for each row, that passes
the
> > id
> > > of
> > > the row as atttribute or parameter
> > > 5 - I have the place holders identified (two div tags)
> > >
> > > How shoul I implement the ajax call for the search and the detail?
> > Please,
> > > step by step explanatuion if possble.
> > > My big problem is how to do this call, i tried some approaches to
> solve
> > > this, but none was sucessful.
> > >
> > > Thanks everyone.
> > >
> > > --
> > > 
> > > We shall go on to the end.
> > > We shall fight in France
> > > We shall fightover the seas and oceans.
> > > We shall fight with growing confidence and growing strength in the
> air.
> > > We shall defend our island whatever the cost may be
> > > We shall fight on beaches, we shall fight on the landing grounds,
> > > We shall fight in the fields and in the streets,
> > > We shall fight on the hills.
> > > We shall never surrender.
> > > Winston Churchill
> > >
> > >
> >
> >
> > --
> > Thanks, Karthik
> >
> >
>
>
> --
> 
> We shall go on to the end.
> We shall fight in France
> We shall fightover the seas and oceans.
> We shall fight with growing confidence and growing strength in the air.
> We shall defend our island whatever the cost may be
> We shall fight on beaches, we shall fight on the landing grounds,
> We shall fight in the fields and in the streets,
> We shall fight on the hills.
> We shall never surrender.
> Winston Churchill
>
>


--
Jesse Kuhnert
Tapestry/Dojo/(and a dash of TestNG), team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com





--

We shall go on to the end.
We shall fight in France
We shall fightover the seas and oceans.
We shall fight with growing confidence and growing strength in the air.
We shall defend our island whatever the cost may be
We shall fight on beaches, we shall fight on the landing grounds,
We shall fight in the fields and in the streets,
We shall fight on the hills.
We shall never surrender.
Winston Churchill


EventListener can update a For component ?

2006-09-21 Thread Roberto Ramírez Vique

Hi everybody,

I'm an starter in Tapestry 4.1, using tomcat 5.5 and jdk 1.5

I want to have a link (a plus image :P) that adds a new element to the for
loop. I tried this:

   @EventListener(elements="addLink", events="onclick",
submitForm="userForm", async=true)
   public void addNewRequester(IRequestCycle cycle){
   this.getLoanAdvice().getRequesters().add(new
PersonEconomicEvaluation());

   cycle.getResponseBuilder().updateComponent("requestersLoop");
   }

The html is this:

   
   
   
   
   
   

Obviously, "requesterLoop" is a loop over the
getLoanAdvice().getRequesters() ... the method 'addNewRequester' is supose
to add a new item in the for loop. The serverside is called, but the client
side doens't update correctly, eventhough I call the '
cycle.getResponseBuilder().updateComponent("requestersLoop");' method... I
tried updating directly the entire form, but doesn't work.

My first question is, is it possible ?

And the second one is, can any of you see what I'm missing?

Thanks in advance,
--
Robert Ramírez Vique
Computer Science Engineer


Re: java.io.NotSerializableException - tapestry property

2006-09-21 Thread Josh Joy
Hi Jesse,

Yes, the problem is that it's being serialized. If I
properly implement 
java.io.Serializable on the object, then the error
goes away.

I'm just thinking for some reason though that I
vaguely remember the 
Tapestry documentation mentioning this and providing 3
different 
solutions to remedy the problem though I can't find
the link...I've 
googled, searched my history etc...(very
frustrating)

Thanks,
Josh

Jesse Kuhnert wrote:
> Is it a parameter that is being serialized? You
haven't provided the full
> stack trace so it's impossible to say why...(Other
than the obvious that
> some user defined object you are using isn't
java.io.Serializable  ;) )
>
> On 9/21/06, Peter Dawn <[EMAIL PROTECTED]> wrote:
>>
>> i think your output file is missing. the fill you
are trying to write
>> to does not exist.
>>
>>
-
>> To unsubscribe, e-mail:
[EMAIL PROTECTED]
>> For additional commands, e-mail:
[EMAIL PROTECTED]
>>
>>
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Is breadcrumbs component hard in Tapestry?

2006-09-21 Thread Vjeran Marcinko

Hello all.

I tried to develop my breadcrumbs component, but it seems that it is a bit 
harder than expected to do it in component framework.


Anyway, has anyone developed the same and is willing to share? IMPORTANT 
NOTE: this breadcrumb component should be dynamic in nature, not using only 
PageLinks to render links, but also DirectLinks (or whatever) to be able to 
pass some additional argument required for displaying some breadcrumb page. 
Typical case is when some breadcrumb link is leading to some EntityHome page 
of some db entity that requires entity ID to be displayed.


Regards,
Vjeran


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]