@a5rocks/

programmatic file writing test

Python

No description

fork
loading
Files
  • main.py
  • test.txt
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
from flask import Flask, request

app = Flask(__name__)

@app.route('/')
def get_params():
	param = request.args.get('test')

	with open('test.txt', 'a') as f:
		f.write(str(param)+'\n')
	
	return 'Done!'

app.run(host='0.0.0.0', port=8080)