{"author_name":"piro_suke","author_url":"https://blog.hatena.ne.jp/piro_suke/","categories":["\u30d7\u30ed\u30b0\u30e9\u30df\u30f3\u30b0"],"url":"https://blog.honjala.net/entry/blog/2009/11/04/200911041257321935/","provider_name":"Hatena Blog","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fblog.honjala.net%2Fentry%2Fblog%2F2009%2F11%2F04%2F200911041257321935%2F\" title=\"Django\u3068PIL\u3067\u753b\u50cf\u306e\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u3092\u53d6\u5f97 - \u307b\u3093\u3058\u3083\u30fc\u306d\u3063\u3068\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","description":"\u753b\u50cf\u3092\u5916\u90e8URL\u304b\u3089\u53d6\u5f97\u3059\u308b\u969b\u306b\u753b\u50cf\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u304c\u5206\u304b\u3089\u306a\u3044\u5834\u5408\u3001\u4e0b\u8a18\u306e\u65b9\u6cd5\u3067\u53d6\u5f97\u3067\u304d\u305f\u3002 Python Imaging Library\u3068Django\u3092\u4f7f\u3063\u305f\u65b9\u6cd5\u3002 import urllib from PIL import Image from django.core.files.base import ContentFile image_url = \"\u753b\u50cf\u30d5\u30a1\u30a4\u30eb\u306eURL\" f = urllib.urlopen(image_url) # \u3053\u308c\u3067\u53d6\u5f97\u3067\u304d\u308b\u304b\u3068\u601d\u3063\u305f\u3051\u3069\u3001\u300capplication/octet-strem\u300d\u3068\u304b\u3060\u3068\u5206\u304b\u3089\u306a\u3044 ## file_info = f.info() ##\u2026","blog_url":"https://blog.honjala.net/","version":"1.0","blog_title":"\u307b\u3093\u3058\u3083\u30fc\u306d\u3063\u3068","width":"100%","image_url":null,"published":"2009-11-04 17:05:35","height":"190","title":"Django\u3068PIL\u3067\u753b\u50cf\u306e\u30d5\u30a9\u30fc\u30de\u30c3\u30c8\u3092\u53d6\u5f97","provider_url":"https://hatena.blog","type":"rich"}