Returns the object stored in the request with the name of the indicated attribute.
1 http.request.getAttribute
<http.request.getAttribute name='name'/>
Attributes | |||||
---|---|---|---|---|---|
Name | Type | Required | Default | Description | |
Aname | string | Opening mode of the url [modal|new|self]. |
Returns | |
---|---|
Type | Description |
object | Return the object stored in the request with the name of the indicated attribute. |
Example
To obtain an attribute of the request, first it must be created. Two name attribute of id and name are created with the values 3 and 'This is my name' respectively. To check the function, it is asked to show the name attribute on the screen.
Copy
<xsql-script name='http_connection_getAttr'> <body> <http.request.setAttribute name='id'> 3 </http.request.setAttribute> <http.request.setAttribute name='name'> This is my name </http.request.setAttribute> <println> <http.request.getAttribute name='name'/> </println> </body> </xsql-script>