Returns a copie of the text with the initial and final spaces omitted.
1 string.trim
<string.trim>
<value /> !
</string.trim>
Arguments | |||||
---|---|---|---|---|---|
Name | Type | Required | Unique | Nullable | Description |
Evalue | string |
Returns | |
---|---|
Type | Description |
string | A copy of the string of characters with the initial and final spaces removed or the own string if does not contain any initial or final space in blank. |
Exceptions
requires 1 arguments, received: ...
The entry parameter has not been specified.
Remarks
This function allows to remove the blank spaces which can be contained in a text before the beginning or after the final of the same one, so until the first character not blank and after the last character not blank.
Example
Show a string applying the function string.trim:
Copy
<xsql-script name='string_trim'> <body> <set name='a'> STR1 </set> <set name='b'> <string> String <string.trim><a/></string.trim> without spaces. </string> </set> <println><b/></println> </body> </xsql-script>
Returns:
Copy
String STR1 without spaces.