One very popular thing you might want to do with your program that responds to HTTP requests is have it interact with a database. And for a long time the most popular such configuration of these pieces was the LAMP