examples/simple_site/main.py
def _default_handlers(self):
        """ Generate the handlers for this site """
        static_path = os.path.abspath(os.path.join(os.path.dirname(__file__),"static"))
        urls = [
            (r"/static/(.*)", cyclone.web.StaticFileHandler, {"path": static_path}),
        ]
        for p in self.pages:
            handler = p.handler
            handler.site = self
            handler.page = p
            urls.append((p.link.url,handler))
        return urls
def _default_handlers(self):
        static_path = os.path.abspath(os.path.join(os.path.dirname(__file__),"static"))
        urls = [
            (r"/static/(.*)", cyclone.web.StaticFileHandler, {"path": static_path}),
        ]
        for p in self.pages:
            handler = p.handler
            handler.site = self
            handler.page = p
            urls.append((p.link.url,handler))
        return urls
def _default_handlers ( self ) : static_path = os . path . abspath ( os . path . join ( os . path . dirname ( __file__ ) , "static" ) ) urls = [ ( r"/static/(.*)" , cyclone . web . StaticFileHandler , { "path" : static_path } ) , ] for p in self . pages : handler = p . handler handler . site = self handler . page = p urls . append ( ( p . link . url , handler ) ) return urls
Generate the handlers for this site
Generate the handlers for this site