MOON
Server: Apache
System: Linux 54-179-220-51.cprapid.com 3.10.0-1160.144.1.el7.tuxcare.els4.x86_64 #1 SMP Tue Apr 7 08:40:40 UTC 2026 x86_64
User: thehunarfound (1001)
PHP: 7.4.29
Disabled: NONE
Upload Files
File: /home/thehunarfound/www/sms/lib/old_config.php
<?php error_reporting(0);session_start();
header("Content-Type: text/html; charset=utf-8");
//ob_start(); 
$dir = "lib/";
if(file_exists($dir."DB.php"))
{
	include_once($dir."DB.php");
	$db = new DB();
	include_once($dir."functions.php");
	include_once($dir."constants.php");
	include_once($dir."common_function.php");
	//include_once($dir."Jfunctions.php");
	$db_old = new connect();
}
else
{
	include_once("../".$dir."DB.php");
	$db = new DB();
	include_once("../".$dir."functions.php");
	include_once("../".$dir."constants.php");
	include_once("../".$dir."common_function.php");
	//include_once("../".$dir."Jfunctions.php");
	$db_old = new connect();
}
$sql="SELECT cofig_name,default_value FROM sg_settings WHERE id=1";
$lngRS=$db->ExecuteQuery($sql);
list($cofig_name,$default_value)=$lngRS->FetchAsArray();

if(!isset($_SESSION['sg_lang']) && empty($_SESSION['sg_lang']))
	$_SESSION['sg_lang']=$default_value;
elseif(isset($_SESSION['sg_lang']) && $_SESSION['sg_lang']!="en" && $_SESSION['sg_lang']!="es" )
{
	$_SESSION['sg_lang']=$default_value;
}
if(isset($_GET['lang']) && ($_GET['lang']=="en" || $_GET['lang']=="es") )
	$_SESSION['sg_lang']=makeClean($_GET['lang']);
elseif(!isset($_SESSION['sg_lang']))
	$_SESSION['sg_lang']=$default_value;	

$sql_utf1="SET CHARACTER SET utf8";
	$db->ExecuteQuery($sql_utf1);
$sql_utf2="SET NAMES utf8";
		$db->ExecuteQuery($sql_utf2);
?>