Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Scenario - using a server side include in a html page. It generates a question and then, based on the answer given, outputs result. Once user has used tool it should only show the result, not the question in that user-browser session. This must all be done by a ssi within the html page, cannot display result on other page etc. Using standard cgi session 'api' doesn't work as the html page has already written the header, so the writing the session cookie to a header in the ssi fails, and appending the session id to the url is not an option. Any ideas ?
TIA

janitored by ybiC: Retitled with leading "(OT)" to reflect that the post doesn't appear to have anything to do with Perl or perl

Replies are listed 'Best First'.
Re: (OT) server side includes and sessions
by Anonymous Monk on Feb 09, 2004 at 20:28 UTC

    You could always include as part of the SSI output an image that is generated via a script. You could then send the cookie header with the image. Or, you could output javascript to handle the cookie for you. Both of these options are quite horrible ideas really. Perhaps either you or your boss should reconsider this foolish " This must all be done by a ssi within the html page, cannot display result on other page etc" ideology.