#include <mysql/mysql.h>
#include <stdlib.h>
Go to the source code of this file.
Functions | |
int | cgisession_init_mysql_connection (char *host, char *username, char *password, char *database, unsigned int port) |
int | cgisession_have_mysql_connection (MYSQL *m) |
int | cgisession_load (char *key) |
int | cgisession_save () |
int | cgisession_new () |
void | cgisession_free () |
int | cgisession_set_data (void *data, unsigned int size) |
void * | cgisession_get_data () |
char * | cgisession_get_key () |
void | cgisession_dump () |
|
prints the cgisession structure to stdout Definition at line 246 of file mycgisession.c. References CGISESSION_struct::data, CGISESSION_struct::encoding, CGISESSION_struct::key, CGISESSION_struct::size, CGISESSION_struct::stored, and CGISESSION_struct::timeout. |
|
Frees up data allocated for the session.. Definition at line 206 of file mycgisession.c. |
|
Get's the data for the cgi session.. Definition at line 230 of file mycgisession.c. References CGISESSION_struct::data. |
|
gets the key for the current cgisession Definition at line 238 of file mycgisession.c. References CGISESSION_struct::key. |
|
This overloaded function to use if you allready have a mysql connection you want to use Definition at line 103 of file mycgisession.c. |
|
Creates the connection to the mysql database. Must be called before any other function in this library can be called. Definition at line 77 of file mycgisession.c. |
|
If session_key is NULL, this will initiate a new session otherwise it updates the old session indicated by session_key. Calling this function will override values set by calls to the cgisession_option_* functions. If no session exist with the given key, then this function returns NULL. Otherwise it return the newly generated session_key. Definition at line 127 of file mycgisession.c. References cgisession_update(), and CGISESSION_struct::stored. |
|
Creates a new cgisession. This will not be reflected in the database before cgisession_save() has been called. return 0 on success. Definition at line 198 of file mycgisession.c. References CGISESSION_struct::key. |
|
Saves the cgi session to the database Definition at line 145 of file mycgisession.c. References CGISESSION_struct::key, CGISESSION_struct::size, CGISESSION_struct::stored, and CGISESSION_struct::timeout. |
|
Set's the data for the cgi session.. Definition at line 216 of file mycgisession.c. References CGISESSION_struct::data, and CGISESSION_struct::size. |