def writeText(fileName, content, encoding='utf8'):
 try:
  fp = codecs.open(fileName, mode='w+', encoding=encoding)
  fp.write(content)
  fp.close()
  logger.log(CUSTOM_LOGGING.SYSINFO, ('"%s" write to Text file "%s"' % (content, fileName)))
 except Exception as e:
  logger.log(CUSTOM_LOGGING.WARNING, e)

def writeText ( fileName , content , encoding = 'utf8' ) : try : fp = codecs . open ( fileName , mode = 'w+' , encoding = encoding ) fp . write ( content ) fp . close ( ) logger . log ( CUSTOM_LOGGING . SYSINFO , ( '"%s" write to Text file "%s"' % ( content , fileName ) ) ) except Exception as e : logger . log ( CUSTOM_LOGGING . WARNING , e )
write file with given filename and encoding .