Faster images = faster websites. Vary image sizes = faster websites, better user experience. Let's do this Cloudflare.
In this one we only use:
- Cloudflare Images
- python requests
- Django 5 (4.2+)
- python-decouple
Thank you to Cloudflare for sponsoring this one! Be sure to sign up at [ Ссылка ]
Cloudflare for Devs:
Part 1: [ Ссылка ]
Part 2 (this): [ Ссылка ]
Blog post: [ Ссылка ]
Code: [ Ссылка ]
00:00:00 Welcome
00:01:10 Demo
00:04:03 Create Image and BlogPost Models
00:08:34 Set up Cloudflare Images and API Keys
00:14:15 Python Functions to Upload or Get Images
00:19:55 Register the Blog Model in the Django Admin
00:23:39 Upload to Cloudflare Images via Django Admin
00:30:42 Save Cloudflare IDs for Images Uploaded
00:33:36 Display Cloudflare Images in the Django Admin
00:38:01 Cloudflare Image Variants
00:44:45 Thank you
Speed up your Django Images with Cloudflare
Теги
install django with pipvirtualenvweb application developmentinstalling django on macpipdjangobeginners tutorialinstall pythonpython3.8python djangoweb frameworkswindows pythonmac pythoninstall python macvirtual environmentsbeginner pythonpython tutorialdjangocfe2021digitaloceanproductionpythondjango3.2web appsmodern software developmenttrydjango2021