| Server IP : 27.254.152.13 / Your IP : 216.73.217.38 Web Server : Apache/2 System : Linux ns1-252017.dragonhispeed.com 5.2.0 #1 SMP Fri Mar 29 22:50:14 MSK 2024 x86_64 User : coloflew ( 1072) PHP Version : 5.6.40 Disable Function : exec,system,passthru,shell_exec,proc_close,proc_open,dl,popen,show_source,posix_kill,posix_mkfifo,posix_getpwuid,posix_setpgid,posix_setsid,posix_setuid,posix_setgid,posix_seteuid,posix_setegid,posix_uname MySQL : ON | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /home/coloflew/domains/fulltion.com/public_html/lib/ |
Upload File : |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<head></head>
<html>
<body>
<OBJECT ID="bxlib" name="bxlib"
CLASSID="CLSID:DB0546C7-7735-4A16-A89D-99199EA53FB1"
CODEBASE="TaBXBL.CAB#version=1,0,0,9" style="display:none;">
</OBJECT>
<script type='text/javascript'>
var bxlib = document.getElementById('bxlib');
<?php
$dbi['sql_username'] = base64_decode($_GET['U']);
$dbi['sql_password'] = base64_decode($_GET['P']);
$dbi['sql_host'] = 'localhost'; //base64_decode($_GET['H']);
$dbi['sql_dbname'] = base64_decode($_GET['D']);
//echo '<pre>';print_r($dbi);exit;
########## Database Info ##########
define( "DB_SERVER", $dbi['sql_host'] );
define( "DB_NAME", $dbi['sql_dbname'] );
define( "DB_USER", $dbi['sql_username'] );
define( "DB_PASSWD", $dbi['sql_password'] );
define( "DB_PREFIX", "tasoft_" );
define( "DB_TYPE", "MySQL" );
########## Type File ##########
define( "FILE_TYPE", "txt,pdf,doc,zip,rar,xls,xlsx,docx,ppt,pptx,swf,wma,3gp,mp4,avi,flv" );
define( "IMAGE_TYPE", "gif,jpg,png" );
define( "IMAGE_SIZE", "51200000" );
define( "FILE_SIZE", "524288000" );
define( "TIMESTAMP", time() );
//define('PATH', 'D:\xampp\htdocs\senahome');
define("END_TRANSACTION",true);
require_once('class/SC_Query.php');
require_once('class/SC_Mysql.php');
require_once('class/SC_Master.php');
require_once('class/SC_Email.php');
require_once('class/SC_Function.php');
$db = new SC_Query();
$objMaster = new SC_Master();
$objFun = new SC_Function();
if(isset($_SESSION['lang_code']) && @$_GET['lang']){
//$la = $_GET['lang'] ? $_GET['lang'] : "En";
$_SESSION['lang_code'] = $_GET['lang'];
$lang_code = $_SESSION['lang_code'];
}elseif(isset($_SESSION['lang_code'])){
$lang_code = $_SESSION['lang_code'];
}else{
$lang_code = "En";
$_SESSION['lang_code'] = $lang_code;
}
$lang_value = $db->getAll('language_value','*',"lang_code='".$lang_code."'");
//echo "<pre>"; print_r($lang_value);
if($lang_value){
$lang_set = array();
foreach($lang_value as $ke => $va){
$lang_set[$va['name']] = $va['value'];
//echo $lang_set[$va['name']];
//$lang = $lang_f;
}
}
$GetInvoiceID = array();
if(isset($_GET['InvoiceID']))
{
unset($_SESSION['SSInvoiceReport']);
$_SESSION['SSInvoiceReport'][] = $_GET['InvoiceID'];
}
//$_SESSION['SSInvoice'] = $_GET['InvoiceID'];
$GetInvoiceID = $_SESSION['SSInvoiceReport'];
//$GetInvoiceID['end'] = '0';
//$GetInvoiceID = $_SESSION['SSInvoice'];
unset($_SESSION['SSInvoiceReport']);
foreach($GetInvoiceID as $val){
$GetInvoice = $db->getOne( "invoice", "*"," InvoiceID = '".$val."'","" );
$Getproduct = $db->getAll( "invoicedetail", "*"," InvoiceID = '".$GetInvoice['InvoiceID']."'","Order By InvoiceDetailID" );
$sendRes = $db->getOne("customer","*"," CustomerID='".$GetInvoice['InvoiceSendID']."'");
$StartDelivery = $db->getOne("deliverypoint","*"," DeliveryPointID='".$GetInvoice['InvoiceStartPoint']."'");
$EndDelivery = $db->getOne("deliverypoint","*"," DeliveryPointID='".$GetInvoice['InvoiceSetEndPoint']."'");
$StartProvince = $db->getOne("province","*"," PROVINCE_ID='".$StartDelivery['DeliveryPointProvince']."'");
$EndProvince = $db->getOne("province","*"," PROVINCE_ID='".$EndDelivery['DeliveryPointProvince']."'");
}
$strText = "";
@$arrData = array();
@$CheckInvoice = $db->getOne("barcode_reprint","MAX(ReprintId) as ReprintId","InvoiceCode = '" . @$GetInvoice['InvoiceCode'] . "'");
//echo "<pre>";
//print_r(@$CheckInvoice['ReprintId'] );
//exit();
@$arrData['ReprintId'] = @$CheckInvoice['ReprintId'] = 0 ? 1 : @$CheckInvoice['ReprintId'] + 1;
@$arrData['InvoiceCode'] = $GetInvoice['InvoiceCode'];
//echo @$arrData['ReprintId'];
@$strReprint = @$arrData['ReprintId'];
foreach($Getproduct as $key => $va){
if($strText==""){
if (@$CheckInvoice['ReprintId'] > 1)
{
@$strInvoiceCode = $GetInvoice['InvoiceCode'] . "(" . (@$strReprint > 1 ? @$strReprint - 1 : @$strReprint ) . ")";
}
else
{
@$strInvoiceCode = $GetInvoice['InvoiceCode'];
}
$strText = sprintf(
"{Province: \"%s\",Inv: \"%s\",Dvp: \"%s\",Point: \"%s\",Bc: \"%s\",Dt: \"%s\"}",
$StartProvince['PROVINCE_NAME']."-".$EndProvince['PROVINCE_NAME'],
//$GetInvoice['InvoiceCode'],
@$strInvoiceCode,
$EndDelivery['DeliveryPointCode'],
$StartDelivery['DeliveryPointName']."-".$EndDelivery['DeliveryPointName'],
$va['ProductCode'],
// part p'แก๊บ $objMaster->getdbdateformat(@$GetInvoice['InvoiceDate'])
$objMaster->getdbdateformat_barcode(@$GetInvoice['InvoiceDate'])
);
}else{
if (@$CheckInvoice['ReprintId'] > 1)
{
@$strInvoiceCode = $GetInvoice['InvoiceCode'] . "(" . (@$strReprint > 1 ? @$strReprint - 1 : @$strReprint ) . ")";
}
else
{
@$strInvoiceCode = $GetInvoice['InvoiceCode'];
}
$strText .= sprintf(
",{Province: \"%s\",Inv: \"%s\",Dvp: \"%s\",Point: \"%s\",Bc: \"%s\",Dt: \"%s\"}",
$StartProvince['PROVINCE_NAME']."-".$EndProvince['PROVINCE_NAME'],
//$GetInvoice['InvoiceCode'],
@$strInvoiceCode,
$EndDelivery['DeliveryPointCode'],
$StartDelivery['DeliveryPointName']."-".$EndDelivery['DeliveryPointName'],
$va['ProductCode'],
//p'แก๊บ $objMaster->getdbdateformat(@$GetInvoice['InvoiceDate'])
$objMaster->getdbdateformat_barcode(@$GetInvoice['InvoiceDate'])
);
//echo "<pre>"; print_r($strText);
}
}
echo "var arr = new Array($strText);";
@$ReprintId = $db->insertData('barcode_reprint',$arrData);
?>
//alert(arr);
for(var i=0;i<arr.length;i++){
bxlib.BeginDoc();
bxlib.SetFont("AngsanaUPC", 18, true);
bxlib.PrintText(100, 10, arr[i].Province);
bxlib.SetFont("AngsanaUPC", 18, true);
bxlib.PrintText(25, 85, arr[i].Inv);
bxlib.PrintText(500, 85, arr[i].Dvp);
bxlib.PrintText(25, 130, arr[i].Point);
bxlib.PrintBarCode(14, 200, 100, arr[i].Bc);
bxlib.PrintText(430, 320, arr[i].Dt);
bxlib.PrintText(25, 320, (i+1).toString() + "/" + arr.length.toString());
bxlib.EndDoc();
}
setTimeout('window.close()',1000);
</script>
</body>
</html>