Using Static Files With Flask - Python and Flask #7

preview_player
Показать описание
In this video I'll show you how to use Static Files with Flask and Python.

Every website online uses static files...images, css, and javascript. Flask makes using static files super easy. All you have to do is create a static directory and place your static files inside of it. Then simply reference them using regular links or Flask url_for tags.
Рекомендации по теме
Комментарии
Автор

▶️ Watch Entire Flask Playlist ✅ Subscribe To My YouTube Channel:
▶️ See More At: ✅ Join My Facebook Group:

Codemycom
Автор

I have started watching this series from #1 and.... It is the best and easiest tutorial to follow through with. 10/10. Thank you for the videos. These should be getting more views.

justtutorials
Автор

All flask videos are really helpful. Thanks codemy.

bhavikjain
Автор

When I deploy the flask app on kubernetes, I get 404 on static files even when I try the method mentioned in this video, there is no sub folder created, only static and inside static folder, I have css and JS. What can be the issue? I have an ingress file with /test as path prefix

rameshgaming
Автор

I've followed the video exactly but my CSS doesn't work!
When I try to add my style.css file, it just doens't work and I can't figure out why. The background before the style.css is linked is white, when I add my style.css=blue background, the background turns black...

Any idea?

paigehughes
Автор

When I make changes to style.css they don't reflect on the site. Even when I stop the server and restart the site loads the old css?

ivanyosifov
Автор

Hi John, How do you handle css files when you have multiple pages that use different stylesheets?

samuxel
Автор

Sir I can't add background image to my pages. Can you please help me in this occasion????

donasunny
Автор

Hello, I did this and added my css through static folder but the thing is it does not load the css file it only loads the images in the static file. what might be the problem

peterkaranja
Автор

Mate, I'm looking everywhere for a way to use the background-image: url() property in a css file but nowhere is a working way. Maybe I'm doing something wrong, it's hard to say. Do you have any advice or ready-made solution?

dawidpaubiak
Автор

The more I work with flask the more I hate it. Use Django instead. Flask is absolute garbage. Can’t even put a background image on a webpage.

youtubeiscorrupt