XML Feeds

.

[javascript-dev] Re: Navigating Folders... going "up"

sean ahern sxa at whiterabbitdesign.co.uk
Fri May 30 04:38:05 MDT 2008




Looking at the code for jsfolderiter.js, it looks as though it always uses'/' as its own path separator.  Do you really need to worry about cross-platform path handling?  Unless Im missing something, shouldnt the following suffice??

    var folderString = new String(fodlerName);
    lastSep = folderString.lastIndexOf('/',folderString.length-2);
    folderString = folderString.slice(0,lastSep);


Alternately, would your application suffice with just

C:\Stuff\Junk\.. 

?



More information about the javascript-dev mailing list