java图片上传转base64

public voidimportExcel(@RequestParam("file") MultipartFile file) throws IOException {
        BASE64Encoder encoder = new BASE64Encoder();
        String imageString = "data:image/jpg;base64," + encoder.encode(file.getBytes());
}
  • 2020-12-18 15:59:48

Load More