public class AjaxTextHinter extends AjaxDynamicElement
The default value for the field comes from setting default = "something"; on the input element. For instance, to set the default value on a text field, you would do <wo:WOTextField value = "$value" default = "Fill this in"/>.
If you place this tag around your forms or input elements, all input elements and forms are automatically re-registered after an Ajax-Refresh when placed within an AjaxUpdateContainer.
Example 1: Given form and all input elements are registered on load (old behaviour of AjaxTextHinter)
<wo:Form id="myform" ...> <wo:WOTextField default="Login name"/> </wo:Form> <wo:AjaxTextHinter form="myform"/>Example 2: Form is within AjaxUpdateContainer and has to be re-registered after Ajax refresh. So you can nest multiple AjaxTextHinter tags, if necessary
<wo:AjaxUpdateContainer> <wo:AjaxTextHinter> <wo:Form id="myform" ...> <wo:WOTextField default="Login name"/> </wo:Form> </wo:AjaxTextHinter/> </wo:AjaxUpdateContainer>Example 3: only some input elements are within AjaxUpdateContainer
<wo:AjaxTextHinter> <wo:Form id="myform" ...> <wo:AjaxUpdateContainer> <wo:AjaxTextHinter> <wo:WOTextField default="Login name"/> </wo:AjaxTextHinter/> </wo:AjaxUpdateContainer> </wo:Form> </wo:AjaxTextHinter/>
Name | Description |
---|---|
form | ID of the form to apply the hints to |
ERXDynamicElement.ContextData<T>
log
Constructor and Description |
---|
AjaxTextHinter(String name,
NSDictionary associations,
com.webobjects.appserver.WOElement children) |
Modifier and Type | Method and Description |
---|---|
protected String |
_containerID(com.webobjects.appserver.WOContext context)
Override this method and return an update container ID this element should react on.
|
protected void |
addRequiredWebResources(com.webobjects.appserver.WOResponse response,
com.webobjects.appserver.WOContext context)
Override this method to append the needed scripts for this component.
|
void |
appendToResponse(com.webobjects.appserver.WOResponse response,
com.webobjects.appserver.WOContext context)
Overridden to call
AjaxDynamicElement.addRequiredWebResources(WOResponse, WOContext) . |
com.webobjects.appserver.WOActionResults |
handleRequest(com.webobjects.appserver.WORequest request,
com.webobjects.appserver.WOContext context)
Override this method to return the response for an Ajax request.
|
addScriptResourceInHead, addScriptResourceInHead, addStylesheetResourceInHead, addStylesheetResourceInHead, invokeAction, shouldHandleRequest
afterProcessing, appendTagAttributeToResponse, arrayValueForBinding, arrayValueForBinding, associations, beforeProcessing, bindingIsSettable, bindingNamed, booleanValueForBinding, booleanValueForBinding, hasBinding, id, integerValueForBinding, nameInContext, secureInContext, setValueForBinding, stringValueForBinding, stringValueForBinding, valueForBinding, valueForBinding
addChildElement, appendChildrenToResponse, childrenElements, EmptyGroup, hasChildrenElements, invokeChildrenAction, takeChildrenValuesFromRequest, takeValuesFromRequest, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
valueForBinding, valueForBinding
public AjaxTextHinter(String name, NSDictionary associations, com.webobjects.appserver.WOElement children)
public com.webobjects.appserver.WOActionResults handleRequest(com.webobjects.appserver.WORequest request, com.webobjects.appserver.WOContext context)
AjaxDynamicElement
handleRequest
in interface IAjaxElement
handleRequest
in class AjaxDynamicElement
request
- the current requestcontext
- context of the transactionprotected void addRequiredWebResources(com.webobjects.appserver.WOResponse response, com.webobjects.appserver.WOContext context)
AjaxDynamicElement
addRequiredWebResources
in class AjaxDynamicElement
response
- the current responsecontext
- context of the transactionpublic void appendToResponse(com.webobjects.appserver.WOResponse response, com.webobjects.appserver.WOContext context)
AjaxDynamicElement
AjaxDynamicElement.addRequiredWebResources(WOResponse, WOContext)
.appendToResponse
in class AjaxDynamicElement
response
- the current responsecontext
- context of the transactionprotected String _containerID(com.webobjects.appserver.WOContext context)
AjaxDynamicElement
_containerID
in class AjaxDynamicElement
context
- context of the transactionnull
Copyright © 2002 – 2020 Project Wonder.