One of the persistent headaches of Web application development is the
developer's inability to control the sequence in which application "pages"
are executed. The back button, refresh, bookmarks, double-clicks, and
browsers' inconsistent page-caching behavior all create special problems that
result in everything from "variable undefined" errors to duplicate data
records.
To prevent these errors, developers have often resorted to passing around
flag variables and status variables that make code hard to maintain over
time. In this article, I explore a way to gain positive control of
application page flow in server-side code, resulting in code that is more
robust, more secure, and more reusable.
Controlling Page Sequencing with an Event-Driven State Machine
It has been said that the difference between an in-house application and
commercial software is that for an in-ho... (more)