a
Attribute |
Type |
Required |
Default |
Description |
---|---|---|---|---|
id |
string |
TRUE |
|
The id to assign the component |
href |
string |
TRUE |
|
The URL to call to obtain the content |
preInvokeJS |
string |
FALSE |
|
A javascript snippet that will be invoked prior to the execution of the target href. If provided must return true or false. True indicates to continue executing target... false says do not execute link target. Possible uses are for confirm dialogs. |
afterLoading |
string |
FALSE |
|
Javascript code that will be executed after the remote call has been made |
notifyTopics |
string |
FALSE |
|
Topic names to post an event to after the remote call has been made |
errorText |
string |
FALSE |
|
The text to display to the user if the is an error fetching the content |
showErrorTransportText |
string |
FALSE |
|
true/false - when to show the error message as content when the URL had problems |
name |
string |
TRUE |
|
|
value |
string |
FALSE |
|
|
required |
boolean |
FALSE |
|
|
disabled |
boolean |
FALSE |
|
|
theme |
string |
FALSE |
|
|
template |
string |
FALSE |
|
|
cssClass |
string |
FALSE |
|
|
cssStyle |
string |
FALSE |
|
|
label |
string |
FALSE |
|
|
labelposition |
string |
FALSE |
|
|
tabindex |
string |
FALSE |
|
|
onclick |
string |
FALSE |
|
|
ondblclick |
string |
FALSE |
|
|
onmousedown |
string |
FALSE |
|
|
onmouseup |
string |
FALSE |
|
|
onmouseover |
string |
FALSE |
|
|
onmousemove |
string |
FALSE |
|
|
onmouseout |
string |
FALSE |
|
|
onfocus |
string |
FALSE |
|
|
onblur |
string |
FALSE |
|
|
onkeypress |
string |
FALSE |
|
|
onkeydown |
string |
FALSE |
|
|
onselect |
string |
FALSE |
|
|
onchange |
string |
FALSE |
|
|
Nested Elements
The remote A tag supports nested param elements. <ww:param name="" value=""/>
Handling Results
- Currently the remote a will try to evaluate the results as JavaScript. So the action defined in href should return a javascript snippet that will be executed upon return. Th
- The afterLoading method is called after the the above javascript gets evaluated. The afterLoading javascript does not currrently have access to the returned data.
Example
<ww:a id="'link1'" theme="'ajax'" href="/DoIt.action" errorText="'An error ocurred'" showErrorTransportText="true"><img border="none" src="<%=request.getContextPath()%>/images/delete.gif"/> <ww:param name="'id'" value="'1'"/> </ww:a>
Results in:
<a dojoType="BindAnchor" evalResult="true" id="link1" href="/DoIt.action?id=1" errorHtml="An error ocurred" showTransportError="true"></a>
Here is an example that uses the postInvokeJS. This example is in altSyntax=true:
<ww:a id="test" theme="ajax" href="/simpeResult.action" preInvokeJS="confirm(\'You sure\')">A</ww:a>
Notes
- SITEMESH NOTE: Remember that if you want your results to be executed... and your using sitemesh... you must NOT decorate the request w/ sitemesh.