Skip to content

Commit

Permalink
Code Formatting fixed ^_^
Browse files Browse the repository at this point in the history
  • Loading branch information
KazukiPrzyborowski committed Oct 6, 2024
1 parent 8123f3b commit d0b212b
Show file tree
Hide file tree
Showing 47 changed files with 3,509 additions and 2,540 deletions.
97 changes: 64 additions & 33 deletions NeoSrc/image.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,36 +20,67 @@
$urlfname = "index.php";
$appname = "Neo Source Viewer";
$appver = array(3,0,0,"RC 3");
function version_info($proname,$subver,$ver,$supver,$reltype,$svnver,$showsvn) {
$return_var = $proname." ".$reltype." ".$subver.".".$ver.".".$supver;
if($showsvn==false) { $showsvn = null; }
if($showsvn==true) { $return_var .= " SVN ".$svnver; }
if($showsvn!=true&&$showsvn!=null) { $return_var .= " ".$showsvn." ".$svnver; }
return $return_var; }
$appversion = version_info($appname,$appver[0],$appver[1],$appver[2],$appver[3]." Ver.",null,false);
function redirect($type,$file,$time=0,$url=null,$dbsr=true) {
if($type!="location"&&$type!="refresh") { $type=="location"; }
if($url!=null) { $file = $url.$file; }
if($dbsr==true) { $file = str_replace("//", "/", $file); }
if($type=="refresh") { header("Refresh: ".$time."; URL=".$file); }
if($type=="location") { @session_write_close();
header("Location: ".$file); } return true; }
if(dirname($_SERVER['SCRIPT_NAME'])!=".") {
$basedir = dirname($_SERVER['SCRIPT_NAME'])."/"; }
if(dirname($_SERVER['SCRIPT_NAME'])==".") {
$basedir = dirname($_SERVER['PHP_SELF'])."/"; }
if($basedir=="\/") { $basedir="/"; }
if($_SERVER['PATH_INFO']==null) {
if(@getenv('PATH_INFO')!=null&&@getenv('PATH_INFO')!="1") {
$_SERVER['PATH_INFO'] = @getenv('PATH_INFO'); } }
if($_SERVER['PATH_INFO']!=null) {
$_GET['dir'] = $_SERVER['PATH_INFO']; }
if($_GET['dir']=="1") { $_GET['dir']="/"; }
if(!isset($_GET['dir'])) {
$_GET['dir'] = "/"; }
$_GET['dir']=preg_replace("/(.*?)\.\/(.*?)/", "iDB", $_GET['dir']);
if($urltype==1) {
redirect("location",$urlfname."?dir=".$_GET['dir']."&act=lowview",0,$url,false); }
if($urltype==2) {
redirect("location",$urlfname.$_GET['dir']."?act=lowview",0,$url,false); }
?>
function version_info($proname, $subver, $ver, $supver, $reltype, $svnver, $showsvn)
{
$return_var = $proname." ".$reltype." ".$subver.".".$ver.".".$supver;
if ($showsvn == false) {
$showsvn = null;
}
if ($showsvn == true) {
$return_var .= " SVN ".$svnver;
}
if ($showsvn != true && $showsvn != null) {
$return_var .= " ".$showsvn." ".$svnver;
}
return $return_var;
}
$appversion = version_info($appname, $appver[0], $appver[1], $appver[2], $appver[3]." Ver.", null, false);
function redirect($type, $file, $time = 0, $url = null, $dbsr = true)
{
if ($type != "location" && $type != "refresh") {
$type == "location";
}
if ($url != null) {
$file = $url.$file;
}
if ($dbsr == true) {
$file = str_replace("//", "/", $file);
}
if ($type == "refresh") {
header("Refresh: ".$time."; URL=".$file);
}
if ($type == "location") {
@session_write_close();
header("Location: ".$file);
} return true;
}
if (dirname($_SERVER['SCRIPT_NAME']) != ".") {
$basedir = dirname($_SERVER['SCRIPT_NAME'])."/";
}
if (dirname($_SERVER['SCRIPT_NAME']) == ".") {
$basedir = dirname($_SERVER['PHP_SELF'])."/";
}
if ($basedir == "\/") {
$basedir = "/";
}
if ($_SERVER['PATH_INFO'] == null) {
if (@getenv('PATH_INFO') != null && @getenv('PATH_INFO') != "1") {
$_SERVER['PATH_INFO'] = @getenv('PATH_INFO');
}
}
if ($_SERVER['PATH_INFO'] != null) {
$_GET['dir'] = $_SERVER['PATH_INFO'];
}
if ($_GET['dir'] == "1") {
$_GET['dir'] = "/";
}
if (!isset($_GET['dir'])) {
$_GET['dir'] = "/";
}
$_GET['dir'] = preg_replace("/(.*?)\.\/(.*?)/", "iDB", $_GET['dir']);
if ($urltype == 1) {
redirect("location", $urlfname."?dir=".$_GET['dir']."&act=lowview", 0, $url, false);
}
if ($urltype == 2) {
redirect("location", $urlfname.$_GET['dir']."?act=lowview", 0, $url, false);
}
Loading

0 comments on commit d0b212b

Please sign in to comment.