Thanx
--- In [email protected], Matt Chotin <[EMAIL PROTECTED]> wrote:
> Here's an alternative to Tracy's that I've used:
>
> function trimString(str : String) : String
> {
> var startIdx = 0;
> while(str.indexOf(' ',startIdx) == startIdx)
> ++startIdx;
> var endIdx = str.length-1;
> while(str.lastIndexOf(' ',endIdx) == endIdx)
> --endIdx;
>
> if (endIdx >= startIdx)
> {
> return str.slice(startIdx,endIdx+1);
> }
> else
> {
> return "";
> }
> }
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/