Forums

Beginner Problem - How to get Past Hello World screen?

I am new to PythonAnywhere. I built a basic hangman command line game for self learning and want to see how it can be hosted. So, I created a web app, chosen Custom Virtual Env as this is a basic command line program - no Django or Flask framework involved. It has only 2 .py files (main.py and words.py) and does only one import random No other imports.

Now when I go to the link http://anu618.pythonanywhere.com/ it is showing me the default Hello World page. How do I set it up so that it shows my hangman code's output?

Thank you!

If your hangman program is a console-based one, you'll need to rework it in order to make it a website. It will need to be implemented using a WSGI-based web framework (I would recommend Flask), with views to return HTML code. We have a blog post that outlines the basic steps, so perhaps you could start by going through that, and then expand that to use your hangman code.