Project

General

Profile

« Previous | Next » 

Revision 107

Added by stefan about 19 years ago

Corrected session code.

View differences:

initialize.php
31 31
	// Create database class
32 32
	$database = new database();
33 33
	
34
	// Start a session
35
	if(!defined('SESSION_STARTED')) {
36
		session_name(APP_NAME.'_session_id');
37
		session_start();
38
		define('SESSION_STARTED', true);
39
	}
40
	
41 34
	set_magic_quotes_runtime(0);
42 35
	
43 36
	// Get website settings (title, keywords, description, header, and footer)
......
57 50
	$string_dir_mode = STRING_DIR_MODE;
58 51
	define('OCTAL_DIR_MODE',(int) $string_dir_mode);
59 52
	
53
	// Start a session
54
	if(!defined('SESSION_STARTED')) {
55
		session_name(APP_NAME.'_session_id');
56
		session_start();
57
		define('SESSION_STARTED', true);
58
	}
59
	
60 60
	// Get users language
61 61
	if(isset($_GET['lang']) AND $_GET['lang'] != '' AND !is_numeric($_GET['lang']) AND strlen($_GET['lang']) == 2) {
62 62
	  	define('LANGUAGE', strtoupper($_GET['lang']));

Also available in: Unified diff