25 |
// from where to include auth_*.php modules? |
// from where to include auth_*.php modules? |
26 |
$gblIncDir = "/data/docman2"; |
$gblIncDir = "/data/docman2"; |
27 |
|
|
28 |
// force download (so it won't open in associated application) |
// force download on view (so it won't open in associated application) |
29 |
$gblForceDownload = 1; |
$gblForceDownload = 0; |
30 |
|
|
31 |
// date format |
// date format |
32 |
$gblDateFmt="Y-m-d"; |
$gblDateFmt="Y-m-d"; |
145 |
$url_title="relogin"; |
$url_title="relogin"; |
146 |
} |
} |
147 |
include("$html/footer.html"); |
include("$html/footer.html"); |
|
//phpinfo(); |
|
148 |
} // end function EndHTML |
} // end function EndHTML |
149 |
|
|
150 |
////////////////////////////////////////////////////////////////// |
////////////////////////////////////////////////////////////////// |
1547 |
isset($relogin) && $secHash == $relogin) { |
isset($relogin) && $secHash == $relogin) { |
1548 |
header("WWW-authenticate: basic realm=\"$realm\"") ; |
header("WWW-authenticate: basic realm=\"$realm\"") ; |
1549 |
header("HTTP/1.0 401 Unauthorized") ; |
header("HTTP/1.0 401 Unauthorized") ; |
|
phpinfo(); |
|
1550 |
Error("401 Unauthorized","No trespassing !"); |
Error("401 Unauthorized","No trespassing !"); |
1551 |
} |
} |
1552 |
|
|
1611 |
// TODO : should rather check for escapeshellcmds |
// TODO : should rather check for escapeshellcmds |
1612 |
// but maybe RFC 18xx asserts safe filenames .... |
// but maybe RFC 18xx asserts safe filenames .... |
1613 |
$source = $FN_name ; |
$source = $FN_name ; |
|
print "-- $source -- $FN_name -- $HTTP_POST_FILES[FN] -- "; |
|
|
// phpinfo(); |
|
1614 |
if (! file_exists($source)) { |
if (! file_exists($source)) { |
1615 |
Error("You must select file with browse to upload it!"); |
Error("You must select file with browse to upload it!"); |
1616 |
} |
} |
1806 |
case "Co" : |
case "Co" : |
1807 |
// checkout |
// checkout |
1808 |
Lock("$gblFsRoot/$relDir/$F"); |
Lock("$gblFsRoot/$relDir/$F"); |
1809 |
Download("$gblFsRoot/$relDir/$F"); |
Download("$gblFsRoot/$relDir/$F",1); |
1810 |
exit; |
exit; |
1811 |
case "Ci" : |
case "Ci" : |
1812 |
$F=stripSlashes($F); |
$F=stripSlashes($F); |
1822 |
case "V" : |
case "V" : |
1823 |
// view |
// view |
1824 |
LogIt("$gblFsRoot/$relDir/$F","viewed"); |
LogIt("$gblFsRoot/$relDir/$F","viewed"); |
1825 |
if ($gblForceDownload) { |
Download("$gblFsRoot/$relDir/$F",$gblForceDownload); |
|
Download("$gblFsRoot/$relDir/$F"); |
|
|
} else { |
|
|
header("Content-Disposition: attachment; filename=$F" ); |
|
|
Header("Location: $webRoot".urlpath("$relDir/$F")); |
|
|
} |
|
1826 |
exit; |
exit; |
1827 |
case "Ch" : |
case "Ch" : |
1828 |
StartHTML("(File changes)","All changes chronologicaly..."); |
StartHTML("(File changes)","All changes chronologicaly..."); |