Oops
This commit is contained in:
+1
-1
@@ -141,7 +141,7 @@ function retrieveSchedule(airport, state) {
|
||||
|
||||
|
||||
var xhr = new XMLHttpRequest();
|
||||
xhr.open("POST", "http://"+window.location.hostname+":5000/url", true);
|
||||
xhr.open("POST", "http://"+window.location.hostname+":5000/curl", true);
|
||||
xhr.setRequestHeader('Content-Type', 'application/json');
|
||||
xhr.onreadystatechange = function () {
|
||||
if (xhr.readyState === 4) {
|
||||
|
||||
@@ -50,14 +50,6 @@ def volume():
|
||||
level = os.popen('vol').read()
|
||||
return str(level)
|
||||
|
||||
@app.route('/cmd',methods = ['POST'])
|
||||
def command():
|
||||
if request.method == 'POST':
|
||||
json = request.get_json()
|
||||
output = os.popen("cd /usr/share/dump1090-mutability/html && "+json['command']).read()
|
||||
#output = os.popen(json['command']).read()
|
||||
return str(output)
|
||||
|
||||
@app.route('/curl',methods = ['POST'])
|
||||
def curl():
|
||||
if request.method == 'POST':
|
||||
|
||||
Reference in New Issue
Block a user