in reply to A CGI chained-event theory question
My users have accounts in the web system, their cookies contain only their account names (And, in fact, an MD5 checksum of that name and an internal value to prevent cookie tampering).
All data is stored on the server, each form being inserted into the DB (MySQL) after each submit, it is only after the final submit that the data is collected together (since currently they all share a batch number allocated when you do your first submit), formatted and output into the Summary Page.
All users input is important and should appear on the Summary Page.
What I'm wanting is to have a Summary Page that, after the final Submit, contains the most recent groupings, BUT if a user enters a bunch of items now, and then another bunch 20 minutes later that they should somehow be amalgamated into a single summary saving untidy splotches of their days input all over the Summary Page.
I believe, however, that the answer has come to me - simple, and relatively concise.
Do away with Batch IDs, but put a datestamp on each DB entry. After each Submit, look around for any entries in the Summary Page table from my user in the last 12 hours or so, if found, append my latest item onto that. That way its realtime (as soon as they submit, its attached to a summary somewhere) and if they spread out data entry over a day, it will still be attached to the same Summary for tidiness.
You may find it amazing that it took me days of brainstorming, and eventually the 30 minutes+ it took me to form the above posting to ask you for your opinions... So sue me.
However, in doing so (posting), I seem to have managed to collect my thoughts, and as all good ideas do, came to me last night at 3am in bed.
My thanks for your good answers (even if not entirely related to what I really wanted to say), and bothering to read my drivel.
JP
-- Alexander Widdlemouse undid his bellybutton and his bum dropped off --
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: A CGI chained-event theory question
by Ryszard (Priest) on Feb 04, 2002 at 23:54 UTC |