#NEWLINE# def send_zip( self , fname , data ) : #NEWLINE# #INDENT# ' Sends zip data to client. ' #NEWLINE# self . set_status ( 200 , 'HTTP_OK' ) #NEWLINE# self . set_header ( 'Content-Type' , 'application/zip' ) #NEWLINE# self . set_header ( 'Content-Disposition' , 'attachment; filename={}' . format ( fname ) ) #NEWLINE# self . write ( data ) #NEWLINE# self . finish ( )