During the client/server days, it was common for a client GUI program to talk directly to a database server. Web applications introduced the three-tier model by default: the browser is the client tier, the database the back-end tier, and the web server and its extensions became the middle tier.
This middle tier offered better scalability options, in terms of connection pooling and stateless high transactional volumes. The architecture that goes into this tier is usually called the middle-tier architecture. The software solutions in the middle tier are called the middleware. There are a lot of good examples of middleware: ColdFusion, PHP, J2EE, .NET, and so on and so forth. When a typed language like Java or C# is chosen to implement this middle tier, developers tend to create fairly extensive architectures to support their applications.