NAnt
Help
Function Reference
string::replace |
v0.85 |
Returns a string corresponding to the replacement of a given string with another in the specified string.
string string::replace(str, oldValue, newValue)
| Name | Type | Description |
|---|---|---|
| str | string | input string |
| oldValue | string | A String to be replaced. |
| newValue | string | A String to replace all occurrences of oldValue. |
string::replace('testing string', 'test', 'winn') ==> 'winning string'string::replace('testing string', 'foo', 'winn') ==> 'testing string'string::replace('testing string', 'ing', '') ==> 'test str'string::replace('banana', 'ana', 'ana') ==> 'banana'