Hi. In a public module which I have named "MAIN.VB", I use something
like this:
Public g_strRequestorsPIN As String
Public g_strWebSiteLanguage As String
Public g_dbtSettings_HeaderInfo As New DataTable
Public g_dbtGeneralInfo As New DataTable
Public g_dbtSettings_Locations As New DataTable
Public g_dbtSettings_Targets As New DataTable
Public g_dbtSettings_FooterInfo As New DataTable
etc.
In strRequestorsPIN I store the requestors PIN#, in g_dbtGeneralInfo
(which is a datatable) I store some other settings which are decided
by the user (the requestor) as he goes through the pages of the wizard-
like process I'm implementing, so if the site were used to order, say,
movie tickets, I would store "Alex" in strRequestorsPIN, and the pairs
"NumberOfTickets", "7"
"PricePerTicket", "12"
"DateOfShow", 10/10/2007
etc.... you get the idea.
On the last page of the wizard I show a big table with all the
settings selected by the user, for confirmation. On approval, I send
an email to the 'Production' dept, with all that info, and I also
print a receipt. That's it.
My questions are:
1. Is storing that stuff in global variables, like in desktop
programming, a good idea ? Will these public vars belong to ALL users,
or only to one user ?
(I'm not sure, but I guess that they will apply ACROSS the whole app,
therefore for all users.)
If this is the case, then...
2. I can't use cookies or session states since I have NO control over
the user's privacy settings, so the only thing that's left is
cookieless sessions. Or.... is there an alternative ?
Thank you very much.
Alex.