Browse Source

css img size

master
zeroth 5 years ago
parent
commit
c9c2a4d5cf
  1. 7
      contextualise.py
  2. 4
      static/css/main.css

7
contextualise.py

@ -53,7 +53,6 @@ for path, subdirs, files in os.walk(path):
# print(listofdicts[0]["name"]) #test
dict = {} #dict for the form entries
@app.route("/")
@ -80,7 +79,7 @@ def description():
# assigning html tag on the basis of extension, to be finished when all the files have been sent
if thefile.lower().endswith(('.png', '.jpg', '.jpeg')):
thefile = Markup('<img src="'+thefile+'" />')
thefile = Markup('<img src="'+thefile+'" /> <br />')
#if sound
elif thefile.lower().endswith(('.mp3')):
@ -95,10 +94,10 @@ def description():
Your browser does not support the video tag.
</video> ''')
# return render_template('description.html', form=form, file=thefile, listingdirectories=listingdirectories, listingfiles=listingfiles)
return render_template('description.html', file=thefile)
if __name__ == '__main__':
app.run(debug=True)
app.run(debug=True)

4
static/css/main.css

@ -1,4 +1,8 @@
body{
background: lavender;
color:blue;
}
img{
max-width: 500px;
}
Loading…
Cancel
Save