modifié: superTornado.py
modifié: video.html
This commit is contained in:
parent
46a6e08ed0
commit
e42a199d4f
@ -78,7 +78,7 @@ class AJAXHandler(BaseHandler):
|
|||||||
def post(self):
|
def post(self):
|
||||||
with open("image/temp.jpg", 'rb') as f:
|
with open("image/temp.jpg", 'rb') as f:
|
||||||
data = f.read()
|
data = f.read()
|
||||||
self.set_header('Content-type', 'image/jpg')
|
self.set_header('Content-type', 'image/jpeg')
|
||||||
self.write(data)
|
self.write(data)
|
||||||
self.finish()
|
self.finish()
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
$.ajax({
|
$.ajax({
|
||||||
type: "POST",
|
type: "POST",
|
||||||
url:'/ajax',
|
url:'/ajax',
|
||||||
contentType: "image/jpg",
|
contentType: "image/jpeg",
|
||||||
success: function(data){
|
success: function(data){
|
||||||
$('#image').html(data)}
|
$('#image').html(data)}
|
||||||
});
|
});
|
||||||
|
Reference in New Issue
Block a user