title: How to change modified time for folder?
body: <p>I am taking zip file as input which contains multiple files and folders,I am extracting it and then I want to change the last modified time of each content in zip to some new date and time set by user.</p>
  
  <p>I am using <code>os.utime()</code> to change the date and time, but changes get reflected only to the files and not to the folders inside zip.</p>
  
  <pre><code>timeInStr = raw_input("Enter the new time =format: dd-mm-yyyy HH:MM:SS -")
  timeInDt=datetime.datetime.strptime(timeInStr, '%d-%m-%Y %H:%M:%S')
  timeInTS=mktime(timeInDt.timetuple())
  epochTime=(datetime.datetime(timeInDt.year, timeInDt.month, timeInDt.day, timeInDt.hour, timeInDt.minute, timeInDt.second)-datetime.datetime(1970,1,1)).total_seconds()
  z=zp.ZipFile(inputZipFile,"a",zp.ZIP_DEFLATED)
  for files in z.infolist():
      z.extract(files, srcFolderName)
      fileName=files.filename  
      new= fileName.replace('/',os.path.sep)
      correctName= srcFolderName+os.path.sep+new
      print correctName
      if(correctName.endswith(os.path.sep)):
          correc=correctName[:-1]     
          print correc
          os.utime(correc, (timeInTS, timeInTS))
      else:
          os.utime(correctName, (timeInTS, timeInTS))
  </code></pre>
  
  <p>I am using Python 2.7 as platform</p>