Subversion Repositories ALCASAR

Rev

Rev 2854 | Rev 2929 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 2854 Rev 2926
Line 5... Line 5...
5
require('../lib/acctshow.php');
5
require('../lib/acctshow.php');
6
?>
6
?>
7
<!DOCTYPE html>
7
<!DOCTYPE html>
8
<html>
8
<html>
9
<head>
9
<head>
10
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
10
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
11
<?php
11
<?php
12
if (is_file("../lib/sql/drivers/$config[sql_type]/functions.php"))
-
 
13
	include_once("../lib/sql/drivers/$config[sql_type]/functions.php");
-
 
14
else{
-
 
15
	echo <<<EOM
-
 
16
<title>$l_title</title>
-
 
17
<link rel="stylesheet" href="/css/acc.css">
-
 
18
</head>
-
 
19
<body>
-
 
20
<center>
-
 
21
<b>Could not include SQL library functions. Aborting</b>
-
 
22
</body>
-
 
23
</html>
-
 
24
EOM;
-
 
25
	exit();
-
 
26
}
-
 
27
#choice of language
12
#choice of language
28
$Language = 'en';
13
$Language = 'en';
29
if(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {
14
if(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {
30
	$Langue = explode(',', $_SERVER['HTTP_ACCEPT_LANGUAGE']);
15
	$Langue = explode(',', $_SERVER['HTTP_ACCEPT_LANGUAGE']);
31
	$Language = strtolower(substr(chop($Langue[0]), 0, 2)); 
16
	$Language = strtolower(substr(chop($Langue[0]), 0, 2)); 
Line 57... Line 42...
57
	$l_not_valid =	"The requested operation is not valid. Abnormal exit.";
42
	$l_not_valid =	"The requested operation is not valid. Abnormal exit.";
58
	$l_delete =	"Delete";
43
	$l_delete =	"Delete";
59
	$l_edit_user	= "Edit user :";
44
	$l_edit_user	= "Edit user :";
60
}
45
}
61
 
46
 
-
 
47
if (is_file("../lib/sql/drivers/$config[sql_type]/functions.php"))
-
 
48
	include_once("../lib/sql/drivers/$config[sql_type]/functions.php");
-
 
49
else{
-
 
50
	echo <<<EOM
-
 
51
<title>$l_title</title>
-
 
52
<link rel="stylesheet" href="/css/acc.css">
-
 
53
</head>
-
 
54
<body>
-
 
55
<center>
-
 
56
<b>Could not include SQL library functions. Aborting</b>
-
 
57
</body>
-
 
58
</html>
-
 
59
EOM;
-
 
60
	exit();
-
 
61
}
62
$operators=array( '=','<', '>', '<=', '>=', 'regexp', 'like' );
62
$operators=array( '=','<', '>', '<=', '>=', 'regexp', 'like' );
63
if ($config['sql_type'] == 'pg'){
63
if ($config['sql_type'] == 'pg'){
64
	$operators=array( '=','<', '>', '<=', '>=', '~', 'like', '~*', '~~*', '<<=' );
64
	$operators=array( '=','<', '>', '<=', '>=', '~', 'like', '~*', '~~*', '<<=' );
65
}
65
}
66
$link = da_sql_pconnect ($config) or die('cannot connect to sql databse');
66
$link = da_sql_pconnect ($config) or die('cannot connect to sql databse');