You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Mark Stang <ms...@pingidentity.com> on 2006/06/30 02:08:16 UTC

Any idea how to default a value?

I have a radio group:

<span jwcid="@RadioGroup" selected="ognl:page.visit.currentState.acceptLicense">
    <input type="radio" jwcid="@Radio" value="ognl:@com.pingidentity.fsm.state.impl.LicensingState@ACCEPT"/>Accept the license agreement<br>
    <input type="radio" jwcid="@Radio" value="ognl:@com.pingidentity.fsm.state.impl.LicensingState@REJECT"/>Reject the license agreement
</span> 

This works fine.  The user must select ACCEPT to move on.  However, I need to be able to set the selected value to ACCEPT without user input.  I would prefer to use a HIDDEN value defaulted to ACCEPT.  However, I am not sure how to format it.  What I need is for the page to send ACCEPT to ognl:page.visit.currentState.acceptLicense.  I thought about creating component to do this and having it's default value be ACCEPT, but it seems a bit of overkill.  I think it can be done with a HIDDEN value, but I am not sure of the Tapestry Syntax.  The default value in ognl:page.visit.currentState.acceptLicense is REJECT and I don't want to change that.

Tapestry 3.03.

Thoughts?

thanks,

Mark

Re: Any idea how to default a value?WRONG PageBeginRenderListener

Posted by Gunna Satria <gu...@yahoo.com>.
ups...sorry wrong interpretation there..
  
  Gunna
  
Gunna Satria <gu...@yahoo.com> wrote:  Hi,
  
  why don't you implement PageBeginRenderListener and set your value there.
  
  cheers,
  
  Gunna

Mark Stang  wrote:  I have a radio group:


     [input] Accept the license agreement

     [input] Reject the license agreement
 

This  works fine. The user must select ACCEPT to move on. However, I need to  be able to set the selected value to ACCEPT without user input. I would  prefer to use a HIDDEN value defaulted to ACCEPT. However, I am not  sure how to format it. What I need is for the page to send ACCEPT to  ognl:page.visit.currentState.acceptLicense. I thought about creating  component to do this and having it's default value be ACCEPT, but it  seems a bit of overkill. I think it can be done with a HIDDEN value,  but I am not sure of the Tapestry Syntax. The default value in  ognl:page.visit.currentState.acceptLicense is REJECT and I don't want  to change that.

Tapestry 3.03.

Thoughts?

thanks,

Mark


   
---------------------------------
Want to be your own boss? Learn how on  Yahoo! Small Business. 

 		
---------------------------------
Yahoo! Messenger with Voice. Make PC-to-Phone Calls to the US (and 30+ countries) for 2ยข/min or less.

Re: Any idea how to default a value?PageBeginRenderListener

Posted by Gunna Satria <gu...@yahoo.com>.
Hi,
  
  why don't you implement PageBeginRenderListener and set your value there.
  
  cheers,
  
  Gunna

Mark Stang <ms...@pingidentity.com> wrote:  I have a radio group:


     [input] Accept the license agreement

     [input] Reject the license agreement
 

This  works fine. The user must select ACCEPT to move on. However, I need to  be able to set the selected value to ACCEPT without user input. I would  prefer to use a HIDDEN value defaulted to ACCEPT. However, I am not  sure how to format it. What I need is for the page to send ACCEPT to  ognl:page.visit.currentState.acceptLicense. I thought about creating  component to do this and having it's default value be ACCEPT, but it  seems a bit of overkill. I think it can be done with a HIDDEN value,  but I am not sure of the Tapestry Syntax. The default value in  ognl:page.visit.currentState.acceptLicense is REJECT and I don't want  to change that.

Tapestry 3.03.

Thoughts?

thanks,

Mark


 		
---------------------------------
Want to be your own boss? Learn how on  Yahoo! Small Business.