[Top] [Prev] [Next] [Bottom] [Contents]

SaGetSessData

Returns a pointer to the session data associated with the input session identifier.

Synopsis

#include "SaRnHtml.h"
void* SaGetSessData SUTPROTO((pSaSess sess));

Arguments

sess
A pointer to a session identifier.

Return Values

Pointer to the data associated with the input session identifier.

Description

Returns a pointer to the session data associated with the input session identifier. Returns NULL if the session identifier is invalid or expired. Returns NULL if no data is associated with the session identifier.

Example

pSaSess ctx;
void* data;
int num;

ctx = SaGetCtx();
/***now manipulate the current session data ***/
data = SaGetSessData(ctx);
if(data == NULL)
{
	num = 0;
}
else
{
	num = (int)data;
}
/*** keeping track of how many times this user has been here 
***/
num++;
SaSetSessData((void*) num);

Note: Do not store any data obtained with SaMalloc or stored using SaAddToFree in session data.

See Also



[Top] [Prev] [Next] [Bottom] [Contents]

info@bluestone.com
Copyright © 1997, Bluestone. All rights reserved.