WEB开发网
开发学院软件开发Python Python磁盘文件服务器 阅读

Python磁盘文件服务器

 2012-11-15 21:07:20 来源:WEB开发网   
核心提示:##simplehttpthread.pyfrom BaseHTTPServer import HTTPServerfrom SimpleHTTPServer import SimpleHTTPRequestHandlerfrom SocketServer import ThreadingMixInclass Thre
##simplehttpthread.py
from BaseHTTPServer import HTTPServer
from SimpleHTTPServer import SimpleHTTPRequestHandler
from SocketServer import ThreadingMixIn
class ThreadingServer(ThreadingMixIn,HTTPServer):
    pass
serveraddr=('',8765)
srvr=ThreadingServer(serveraddr,SimpleHTTPRequestHandler)
srvr.serve_forever()

image

Tags:Python 磁盘 文件

编辑录入:爽爽 [复制链接] [打 印]
赞助商链接