-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathform_backup.php
executable file
·100 lines (100 loc) · 3.26 KB
/
form_backup.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
<?php
/*
* Factux le facturier libre
* Copyright (C) 2003-2005 Guy Hendrickx, 2017 Thomas Ingles
*
* Licensed under the terms of the GNU General Public License:
* http://opensource.org/licenses/GPL-3.0
*
* For further information visit:
* http://factux.free.fr
*
* File Name: fckconfig.js
* Editor configuration settings.
*
* * * Version: 5.0.0
* * * * Modified: 07/10/2016
*
* File Authors:
* Guy Hendrickx
*.
*/
include_once("include/headers.php");
include_once("include/finhead.php");
?>
<table width="760" border="0" class="page" align="center">
<tr>
<td class="page" align="center">
<?php
require_once("include/head.php");
if ($user_admin != 'y') {
echo "<h1>$lang_admin_droit</h1>";
include_once("include/bas.php");
exit;
}
$page = explode("/", getenv('SCRIPT_NAME'));#split("/", getenv('SCRIPT_NAME'));#Deprecated
$n = count($page)-1;
$page = $page[$n];
$page = explode(".", $page, 2);#split("\.", $page, 2);#Deprecated
$extension = $page[1];
$page = $page[0];
/* 2005
$script = "$page.$extension";
$directory = $_SERVER['PHP_SELF'];
$base_url = "http://".$_SERVER['SERVER_NAME'];
$script_base = "$base_url$directory";
$base_path = $_SERVER['PATH_TRANSLATED'];
$url_base = ereg_replace("$script", '', "$_SERVER[PATH_TRANSLATED]");
*/
#2015 alpha
#$base_url = $_SERVER['REQUEST_SCHEME']."://".$_SERVER['SERVER_NAME'];
$url_base = str_replace("$page.$extension",'', $_SERVER['DOCUMENT_ROOT'].$_SERVER['PHP_SELF']);
//$path=str_replace("$page.$extension",'', $_SERVER['SCRIPT_FILENAME']);
#var_dump($url_base,$_SERVER);exit;
?>
<form name="dobackup" method="post" action="main.php">
<center>
<table class="page" width="500" border="0" cellpadding="5" cellspacing="1" >
<caption><?php echo $lang_bc_titre ?> </caption>
<tr>
<td class="texte0" colspan="2"><?php echo $lang_bc_host ?> </td>
<td class="texte0" colspan="2"> <input name="dbhost" type="text" class="textbox" value="<?php echo $host; ?>" size="37" maxlength="100">
</td>
</tr>
<tr>
<td class="texte0" colspan="2"><?php echo $lang_bc_bata ?></td>
<td class="texte0" colspan="2"> <input name="dbuser" type="text" class="textbox" value="<?php echo $user; ?>" size="37" maxlength="100">
</td>
</tr>
<tr>
<td class="texte0" colspan="2"><?php echo $lang_bc_bata_pwd ?> </td>
<td class="texte0" colspan="2"> <input name="dbpass" type="password" class="textbox" value="<?php echo $pwd; ?>" size="37" maxlength="100">
</td>
</tr>
<tr>
<td class="texte0" colspan="2"><?php echo $lang_bc_login ?> </td>
<td class="texte0" colspan="2"> <input name="dbname" type="text" class="textbox" value="<?php echo $db; ?>" size="37" maxlength="100">
<input name="path" type="hidden" class="textbox" value="<?php echo $url_base; ?>" size="37" maxlength="100">
</td>
</tr>
<tr>
<td class="texte0" colspan="2"></td>
<td class="texte0" colspan="2"><input name="send2" type="submit" class="textbox" value="<?php echo $lang_enter; ?>"></td>
</tr>
</table>
</center>
</form>
</td>
</tr>
<tr>
<td>
<?php
$aide = 'backups';
include("help.php");
require_once("include/bas.php");
?>
</td>
</tr>
</table>
</body>
</html>