Forums

Web site access methods guidance

Just getting started with PA and web.py. I'd like to require a visitor to enter a name/password when accessing certain pages and thought about using the .htaccess technique, but I didn't find the htpasswd command. Is there a another way?

It's better if you use an authetication method that's build in to your app. .htaccess is ok, but it's not supported on the web server we use (nginx). Here's a bit of a rant about why not.

web.py is quite a bare-bones framework, so you'll have to roll your own auth system (other Python web frameworks tend to have this built in). Here is a very simple one that you can expand into a working system and here is a system based on Postgresql that should be quite simple to convert to MySQL.

Thanks for the suggestions; I'll take a look.