1. скопировать html к py.
или
2. вместо get() написать как в hellp world:
Код: Выделить всё
class MainHandler(tornado.web.RequestHandler):
def get(self):
self.write("Hello, world")
Код: Выделить всё
class MainHandler(tornado.web.RequestHandler):
def get(self):
self.write("Hello, world")
по прежнемуNick писал(а):1. скопировать html к py.
аналогичноNick писал(а):2. вместо get() написать как в hellp world:
эта функция тоже не вызываетсяNick писал(а):def get(self):
Код: Выделить всё
# The main application object:
# the /command/ and /polljason/ use HTTP Basic Authorization to log in.
# the /pollhl/ use HTTP header arguments to log in
application = tornado.web.Application([
(r"/([^\\/]*)", MainHandler, {} ),
(r"/command/(.*)", PollHandler, {} ),
(r"/polljson/(.*)", PollHandlerJSON, {} ),
(r"/query/(.*)", PollHeaderLogin, {} ),
(r"/websocket/(.*)", LinuxCNCCommandWebSocketHandler, {} ),
],
debug=True,
template_path=os.path.join(application_path, "templates"),
static_path=os.path.join(application_path, "static"),
)