It’s time to start winding down. You’ve gone from seeing PHP as some strange, cryptic arrangement of angle brackets and dollar signs to building your own application, including integration with a MySQL database, authentication, redirection, and a decent set of utility functions. You might not be able to sell your modest application for a million dollars. But you should have a good sense of how to think in PHP, and how scripts are structured to solve problems.
Before you can twist and bend this application and your new skills to other purposes, there are still some lingering issues that you need to handle. A few of these are nice haves; and some are downright necessities if you’re going to spend your career writing web applications.
Here are just a few things that you could give your application needs to round out both its usefulness and your skills:
• A better login screen. Nobody likes a bland, gray pop-up dialog box; they want a branded, styled login form.
• Better messaging to indicate whether a user is logged in.
• A way to log out.
• Two levels of authentication: one to get to the main application and then administrator-level authentication to get to a page like show_users.php.
• Some basic navigation. That navigation should change based on a user’s login and the groups to which that user belongs.
These are mostly related to the idea of logging in, and that’s no accident. Whether it’s a good-looking login screen or the ability to group users, you’ll probably spend as much time on the authentication and authorization of your web applications as you do on anything else. Even if you have boilerplate code to get a user name and password, most web pages are structured as components that are only selectively accessible. In other words, a web application shows users different things and gives users different functionality based upon their login. It’s time to get a handle on how to store user credentials, move users around your site, and the issues that underlie keeping up with a user’s information. You’re ready to take your programming into the real world.