Re: Accessing DatabaseAddAction result

2002-12-10 Thread Christian Haul
On 10.Dec.2002 -- 05:57 PM, Matthias Brunner wrote:
> On Tuesday 10 December 2002 17:19, Christian Haul wrote:
> > At least the one from the modular package does set the error
> > message as request attribute.
> 
> Thanks for your reply. Do you know whether this is in 2.1 only? (I 
> cannot grep "setAttribute" in the source file but it could be hidden 
> in other modules)

No, it's in 2.0.4 as well. Only that it does not access the request
object directly but uses o.a.c.c.m.* to do that.

Chris.
-- 
C h r i s t i a n   H a u l
[EMAIL PROTECTED]
fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08

-
Please check that your question  has not already been answered in the
FAQ before posting. 

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




Re: Accessing DatabaseAddAction result

2002-12-10 Thread Matthias Brunner
On Tuesday 10 December 2002 17:19, Christian Haul wrote:
> At least the one from the modular package does set the error
> message as request attribute.

Thanks for your reply. Do you know whether this is in 2.1 only? (I 
cannot grep "setAttribute" in the source file but it could be hidden 
in other modules)

Best regards!
-- 
Matthias Brunner <[EMAIL PROTECTED]>
PGP FP 7862 32B3 3B75 292A F76F  5042 8587 21AB 5B89 D501
Check out http://blumenstrasse.vol.at/~mb/gpgkey.asc


-
Please check that your question  has not already been answered in the
FAQ before posting. 

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




Re: Accessing DatabaseAddAction result

2002-12-10 Thread Christian Haul
On 10.Dec.2002 -- 05:05 PM, Matthias Brunner wrote:
> Hello,
> 
> is there any way to find out whether a DatabaseAddAction was 
> successful / display the error message?
> 
> I would like to do the following:
> 
> 
>   
>   
>   
> 
>   
>   ...
>   ...
> 
> 
> I do not want to have to different input sources dependent on whether 
> the action was successful. Actually, I just want the same form to be 
> reloaded and to display "record added" (or an error message on top 
> of the page).
> I see in the source that DatabaseUpdateAction sets a request 
> attribute "rows" to indicate how many rows where updated.
> Why does DatebaseAddAction not set something like two request 
> attributes "success" and "errorMessage"?

At least the one from the modular package does set the error message
as request attribute.

> Or is this not the cocoon way of doing it? How is this realised 
> without having to rely on xsp? (AFAIK, it is also possible to access 
> request attributes in xsl)

Like you say it is possible to access request attributes from
xslt. Thus you do not need XSP.

Chris.
-- 
C h r i s t i a n   H a u l
[EMAIL PROTECTED]
fingerprint: 99B0 1D9D 7919 644A 4837  7D73 FEF9 6856 335A 9E08

-
Please check that your question  has not already been answered in the
FAQ before posting. 

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