''' SVPlayer http filesystem emulator (c) 2011 Jan ONDREJ (SAL) This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. ''' import sys, re, urllib2 reg_file_line = re.compile('', re.I) def listdir(path): ret = [] f = urllib2.urlopen(path) for line in f.readlines(): r = reg_file_line.search(line) if r and r.group(1)!='../': ret.append(r.group(1).rstrip('\n')) return ret