Exemple #1
0
function generate()
{

	    return barCode(
		$this->p_bcType,
		$this->p_text,
		$this->p_xDim,
		$this->p_w2n,
		$this->p_charGap,
		$this->p_inverted,
		$this->p_charHeight,
		$this->p_type,
		$this->p_textLabel,
		$this->p_rotAngle,
		$this->p_ck,
		$this->p_2File,
		$this->p_fileName);
}
Exemple #2
0
	} else {
		$p_2File = TRUE;
	}
	if ($p_label == "N"){
		$p_textLabel = FALSE;
	} else {
		$p_textLabel = TRUE;
	}
	if ($p_checkDigit == "N"){
		$p_ck = FALSE;
	} else {
		$p_ck = TRUE;
	}

	barCode(
		$p_bcType,
		$p_text,
		$p_xDim,
		$p_w2n,
		$p_charGap,
		$p_inverted,
		$p_charHeight,
		$p_type,
		$p_textLabel,
		$p_rotAngle,
		$p_ck,
		$p_2File,
		$p_fileName);

?>
function EscribeCodigoBarras($cb, $camcod, $x, $y, $pdf)
{
    require_once "../barcode2/core.php";
    require "../config/config.inc.php";
    $connection = mssql_connect($dbServer, $dbUser, $dbPass) or die("Error en la conexion***");
    $carpeta = 'temp/';
    $extension = "jpg";
    // ASIGNO UN NOMBRE PARA LA IMAGEN A GENERAR
    $filenameAIG = $PDFCreationDir . rand(1000000000, 9999999999.0);
    if ($cb != '') {
        // OBTENGO LOS PARAMETROS PARA GENERAR EL CODIGO DE BARRAS
        $query = " EXEC WSDetalleCodigoBarras '" . $camcod . "' ";
        $resultCB = mssql_query($query, $connection) or die("Error: " . $query . "<hr> " . mssql_get_last_message() . "<BR>");
        $row = @mssql_fetch_row($resultCB);
        // GENERO EL CODIGO DE BARRAS Y LO GUARDA EN UN ARCHIVO
        $bc = barCode($row[0], $cb, $row[1], $row[2], $row[3], $row[4], $row[5], $row[6], $row[7], $row[8], $p_check, $row[9], $carpeta . $filenameAIG);
        // INSERTO LA IMAGEN DEL ARCHIVO CREADO EN EL DOCUMENTO
        $pdf->Image($carpeta . $filenameAIG . "." . $extension . "", $x, $y, $row[12], $row[13], '', '');
    }
    return;
}