Tornado – Redirection

Redirections are essential while developing a website. What if you need to redirect a user from a page to home page based on an event? Tornado supports redirection.

In the example below,

  • When you run and open a browser at, you would notice a message, ‘It Works!’ which suggests Tornado Web Server is up and running.
  • On browsing to (HTTP GET), you would notice message ‘Page on articles’ with a button ‘Home’.
  • Button ‘Home’ is a html file that submits a Post request on ‘/article’ page. Class Article¬† handles this HTTP POST request and redirects itself to home page(‘/’).

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.