$DBInfoArray=array(
"default"=>array(
"hosting" => "milkxhak.ipowermysql.com",
"user" => "milkxhak",
"password" => "#Newstart09#",
"database" => "milkxhake",
),
"www.milkxhake.org"=>array(
"hosting" => "milkxhak.ipowermysql.com",
"user" => "milkxhak",
"password" => "#Newstart09#",
"database" => "milkxhake",
),
);
$DBInfo=($DBInfoArray[$_SERVER['SERVER_NAME']])?$DBInfoArray[$_SERVER['SERVER_NAME']]:$DBInfoArray['default'];
$link=mysql_connect($DBInfo['hosting'],$DBInfo['user'],$DBInfo['password']);
mysql_select_db($DBInfo['database'],$link);
mysql_query("SET NAME UTF8");
?>
function loginEncode($a=""){
return base64_encode($a);
}
function loginDecode($a=""){
return base64_decode($a);
}
function FrmVars($a){
if(get_magic_quotes_gpc()===0){$a=addslashes($a);}
return $a;
}
/*
function FrmVars($a,$spaceFlag=""){
if($spaceFlag==""){$a.=" ";
}
$a=addslashes($a);
return $a;
}
*/
function ReturnVars($a,$type="TEXT"){
if(get_magic_quotes_gpc()===0){$a=stripslashes($a);}
if($type!="HTML"){
$a=htmlspecialchars($a);
$a=str_replace("&","&",$a);
$a=nl2br($a);
}
else{
$a=str_replace("$val){
$returnVars[$key]=ReturnFrmVars($val);
}
return $returnVars;
}
}
function ReturnTextareaVars($a,$type="TEXT"){
if(get_magic_quotes_gpc()===0){$a=stripslashes($a);}
if($type!="HTML"){
$a=htmlspecialchars($a);
$a=str_replace("&","&",$a);
$a=nl2br($a);
}
else{
$a=str_replace("";
if(mysql_error()){
echo $DB."
";
echo "mysql_error=".mysql_error()."
";
}
$i=0;
while($tblInfo=mysql_fetch_field($resDB)):
$fieldName[$i]=$tblInfo->name;
$i++;
endwhile;
$i=0;
while($tblData=mysql_fetch_array($resDB,MYSQL_ASSOC)):
for($a=0;$a";
$returnStr.="window.location.replace(\"index.php?page=".$URL."\");";
$returnStr.="";
echo $returnStr;
}
function countryPulldownList($selectedId){
$selectedArray[$selectedId]=" selected";
$countryList=listFun("countries"," order by name");
$returnStr='';
for($a=0;$a".returnFrmVars($countryList[$a]['name'])."";
}
return $returnStr;
}
function fileLog($rootPath,$data){
$filePath=$rootPath."admincp/upload/logs/log.txt";
$nowTime=date("Y-m-d H:i:s")."\n";
$separateLine="\n==================================================================================================\n";
$data=$nowTime.$data.$separateLine;
$fp = fopen($filePath, 'a+');
fwrite($fp, $data);
fclose($fp);
}
function maxOrderingId($tblName){
global $link;
$sql=mysql_query("select max(ordering) from ".$tblName);
list($returnId)=mysql_fetch_row($sql);
return $returnId+1;
}
function uploadOrderingId($tblName,$itemId,$orderingStart,$orderingEnd,$orgId=''){
global $link;
if($orderingStart!=$orderingEnd){
if($orgId!=''){
mysql_query("update ".$tblName." set ordering=ordering-1 where (ordering > '".$orgId."') and id!='".$itemId."'");
}
mysql_query("update ".$tblName." set ordering=ordering+1 where (ordering between ".$orderingStart." and ".$orderingEnd.") and id!='".$itemId."'");
}
}
function uploadOrderingIdByDel($tblName,$orderingId){
global $link;
mysql_query("update ".$tblName." set ordering=ordering-1 where ordering>'".$orderingId."'");
}
?>
$_defaultLang="en";
$_setLang=array("en");
$_setEmailArray=array("info@milkxhake.com");
$_systemEmail="info@milkxhake.com";
$set_checkedArray=array(""," checked");
$set_emailArray=array('info@milkxhake.com');
$statusArray = array("inactive","active");
$set_URL="";
$set_uploadFilePath="./upload/files/";
$set_uploadImgPath="./upload/images/";
$set_uploadLogPath="./upload/logs/";
$set_frontendUploadFilePath="./backend/upload/files/";
$set_frontendUploadImgPath="./backend/upload/images/";
$set_frontendUploadLogPath="./backend/upload/logs/";
$set_shopImgWidth=286;
$set_imageQuality=100;
$set_imageResizeFlag=0;
?>
::::: milkxhake :::::