10-10-2004 11:44
Dunno if anybody will find this useful. I certainly do :). This is a trim() function to clear whitespaces off the beginning and end of a string. Usefull if you're parsing a lot of user input. Not very complicated so a lot of you have probably done something similar. Anyway, have at it :).

string trim(string str)
{
list input_list = llParseString2List(str, [" "], []);
str = llDumpList2String(input_list, " ";);

return str;
}
_____________________