Skip to content

Commit

Permalink
Merge pull request #52 from LetMeFly666/flask
Browse files Browse the repository at this point in the history
记录一个在手机上远程连接电脑写出来的代码
  • Loading branch information
LetMeFly666 authored Oct 20, 2023
2 parents bf25da3 + 239c00b commit 0cdee14
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions png.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
'''
Author: LetMeFly
Date: 2023-10-20 10:00:08
LastEditors: LetMeFly
LastEditTime: 2023-10-20 10:20:27
'''
from flask import send_file, send_from_directory
import flask

app = flask.Flask('1')

@app.route("/a/")
def download_file():
return send_file(r"C:\Users\LetMeFly\Desktop\image.png", 'a.png', as_attachment=True)

print(app.url_map)
app.run(host='0.0.0.0', port='80', debug=True)

0 comments on commit 0cdee14

Please sign in to comment.