I'm trying to make a website in flask and I want to put an image on the website it works using the img tag but I cannot resize or do anything to it. I want to use it as a background and want it to be responsive but I can't, the css files can't find the specified image. Here is the code Thanks in advance.
- 积分
0 - 话题
0 - 评论
3192 - 注册排名
2009
Seems you have the below project directory for the
static
folder:static/ └── css/ └──style.css └── img/ └──image.png
If you are using the above directory structure you can use the below
CSS
commands inCSS
file:This will import the image from
static/img/
and then you can all the CSS tag to make it responsive.