function barDrawSimple($code) { global $SYS; if (is_dir($SYS["DOCROOT"] . "/Extensions/barcodeGen_4v123pl1")) { /************************************** BARCODE */ define('IN_CB', true); set_include_dir($SYS["DOCROOT"] . "/Extensions/barcodeGen_4v123pl1/-"); // Including all required classes require 'class/index.php'; require 'class/Font.php'; require 'class/FColor.php'; require 'class/BarCode.php'; require 'class/FDrawing.php'; // Including the barcode technology include 'class/code39.barcode.php'; // Loading Font $font =& new Font($SYS["DOCROOT"] . '/Data/Fonts/Vera.ttf', 8); // Creating some Color (arguments are R, G, B) $color_black =& new FColor(0, 0, 0); $color_white =& new FColor(255, 255, 255); /* Here is the list of the arguments: 1 - Thickness 2 - Color of bars 3 - Color of spaces 4 - Resolution 5 - Text 6 - Text Font */ $code =& new code39(60, $color_black, $color_white, 2, $code, $font); //$code =& new code39(60,$color_black,$color_white,2,"001492026D67",$font); /* Here is the list of the arguments 1 - Filename (empty : display on screen) 2 - Background color */ $drawing =& new FDrawing('', $color_white); $drawing->setBarcode($code); $drawing->draw(); // Header that says it is an image (remove it if you save the barcode to a file) header('Content-Type: image/png'); // Draw (or save) the image into PNG format. $bardata = $drawing->finish(IMG_FORMAT_PNG); /************************************** BARCODE */ } }
<?php require_once "coreg2.php"; debug("Import elements from CSV", "white"); foreach ($SYS["APPS"] as $app) { set_include_dir($SYS["BASE"] . "/Apps/" . $app . "/."); } $data = file($_FILES["fichero_csv"]["tmp_name"]); $FIELDS = explode(";", current($data)); foreach ($FIELDS as $a => $b) { $FIELDS[$a] = strtolower(trim(strtr($b, "\"'", " "))); } dataDump($FIELDS); foreach ($data as $k => $v) { if ($k != 0) { $DATAFIELDS = explode(";", $v); foreach ($DATAFIELDS as $a => $b) { $DATAFIELDS[$a] = strtr($b, "\"'", ""); } $q = "INSERT INTO {$prefix}_{$table} (`" . implode("`,`", $FIELDS) . "`) VALUES (" . implode(",", $DATAFIELDS) . ")"; _query($q); } }
<?php set_include_dir(dirname(__FILE__) . "/../Extensions/google/translate/-"); require "GTranslate.php";
'; $metadata["menu_entrys_items"] .= ' <div id="menuEntry' . $v . '_box" class="thook" style="display : none; position : absolute; z-index : 1;" onclick="flip(\'none\')"><div class="thookreal">'; foreach ($menu_entry["items"] as $j) { if ($j[3]) { $metadata["menu_entrys_items"] .= '<img src="' . $SYS["ROOT"] . "/Apps/" . $k . "/local/Img/" . $j[3] . ' " align="left" style="margin-top:2px;margin-left:1px;" border="0"/>'; } else { $metadata["menu_entrys_items"] .= '<img src="' . $SYS["ROOT"] . '/Backend/local/Img/menu_none.gif" align="left" style="margin-top:2px" border="0"/>'; } $metadata["menu_entrys_items"] .= ' <a href="' . $j[0] . '" target="' . $j[1] . '" class="tlink"> ' . _rfixed($j[2]) . '</a><br>'; } $metadata["menu_entrys_items"] .= '</div></div>'; $TMI++; } } $metadata["total_menu_items"] = $TMI; set_include_dir(dirname(__FILE__) . "/local/Tmpl/-"); plantHTML($metadata, "mainview"); } else { echo "Not found {$petition}"; header("HTTP/1.0 404 Not Found"); } } /* echo '<div style="padding:10px;border:1px solid gray">'; dataDump($SYS); echo "<hr>"; dataDump($_SESSION); echo '</div>'; */
<?php require_once "coreg2.php"; foreach ($SYS["APPS"] as $v => $k) { set_include_dir($SYS["DOCROOT"] . "../Apps/{$k}/"); //echo $SYS["DOCROOT"]."../Apps/$k"."\n"; } function buildQuery($tokens) { $fields = array($this->properties[$fieldtoshow]); $token = explode(" ", $tokens); foreach ($token as $kk => $vv) { foreach ($fields as $k => $v) { $xmultiquery[] = "{$k} LIKE '%{$vv}%' "; } $multiquery = implode(" OR ", $xmultiquery); unset($xmultiquery); $smultiquery[] = "(" . $multiquery . ")"; } $query = implode(" AND ", $smultiquery); return $query; } $obj = newObject($CL); header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT"); // always modified header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1 header("Pragma: no-cache"); // HTTP/1.0
<?php error_reporting(e_ERROR); require_once dirname(__FILE__) . "/../../coreg2.php"; foreach ($SYS["APPS"] as $apps) { set_include_dir(dirname(__FILE__) . "/../../../Apps/{$apps}/-"); } /* $jjj=newObject("at_importar_datos"); dataDump($jjj); */ if ($function = $_GET['function']) { foreach ($_GET as $k => $v) { if ($k != 'function' && $k != 'CL') { if (is_numeric($v)) { $args[] = $v; } else { $args[] = "'{$v}'"; } } } if ($args) { $args = implode(', ', $args); } if ($CL = $_GET['CL']) { $element = newObject($CL); eval("\$element->{$function}({$args});"); } else { eval("{$function}({$args});"); } }
<?php require_once "coreg2.php"; $SYS["PROJECT"] = "GlobalSche"; set_include_dir(dirname(__FILE__) . "/local/Tmpl/-"); set_include_dir(dirname(__FILE__) . "/-"); set_include_dir(dirname(__FILE__) . "/../Memo/-"); set_include_dir(dirname(__FILE__) . "/../../Framework/Extensions/xajax/-"); function generateJobsToday() { setlimitRows(150000); $d = newObject("gtasklog"); $d->deletes("estado='No iniciada' AND inicio>" . dateTodayStamp()); $u = newObject("gtask"); $ids = $u->allID(); $d = array(); $tasks = array(1); foreach ($ids as $id) { $o = newObject("gtask", $id); $cron = new Parser($o->getCronString()); $RunsToday = $cron->getRuns(time()); foreach ($RunsToday as $timeStampOfRun) { //echo strftime("%d/%m/%Y %H:%M",$cron_ran)." # ".$cron_ran; $tl = newObject("gtasklog"); $tasklog = $tl->getByTaskDate($o, $timeStampOfRun); if ($tasklog) { $tasks[] = $tasklog->ID; //print_r($tasklog); } else { // $tl = newObject("gtasklog");
<?php $SYS["PROJECT"] = $SYS["PROJECT"] ? $SYS["PROJECT"] : "Reports"; require_once "coreg2.php"; set_include_dir(dirname(__FILE__) . "/local/Tmpl/-"); set_include_dir(dirname(__FILE__) . "/-");
</td> </tr> </table> </td> </tr> </table> </form> '; } else { if ($_POST["QB_CMD"] == "condition") { set_include_dir($SYS["DOCROOT"] . "/../Apps/{$modulo}/-"); $clases = unserialize(urldecode($clases)); foreach ($clases as $k => $v) { $o = newObject("{$v}", 1); foreach (array_keys($o->properties) as $n => $p) { $namee = $o->properties_desc[$p]; $data["{$prefix}_{$v}.{$p}"] = "{$v}.{$namee}"; } $data["{$prefix}_{$v}.ID"] = "{$v}.ID"; $from_a[] = "{$prefix}_{$v}"; } $queryx = unserialize(urldecode($queryx)); if (empty($condition3)) { $query = $queryx . " AND {$condition1}{$condition}{$condition2}"; } else { if ($condition2 != 'Funcion') {
<?php require_once "Reports.php"; foreach ($SYS["APPS"] as $ONEAPP) { set_include_dir(dirname(__FILE__) . "/../{$ONEAPP}/-"); } $magic = array(); $ID = isset($ID) ? $ID : 1; $id_curso = isset($id_curso) ? $id_curso : 1; $u = newObject("report", $ID); $u->id_curso = $id_curso; if ($u->tipo == 'HardCoded') { if ($print_mode != "yes") { $dummy = 1; } else { if (!ini_get("output_buffering")) { ob_start(); } } setLimitRows(5000); require_once "reports/{$u->url}.php"; if ($print_mode != "yes") { $dummy = 1; } else { $data = ob_get_contents(); ob_clean(); require_once "Lib/lib_PDF.php"; if ($SYS["GLOBAL"]["spooler"] == "ASPooler") { $cdata = urlencode($data); jsAction("location.href='http://" . $SYS["GLOBAL"]["ip_spooler"] . ":9090?{$cdata}'"); } else {
<?php /* Wrapper for phpmailer */ require_once "coreg2.php"; set_include_dir(dirname(__FILE__) . "/../Extensions/phpmailer/-"); require "class.phpmailer.php";
<?php $SYS["PROJECT"] = "JasperReports"; require_once dirname(__FILE__) . "/../../Framework/coreg2.php"; set_include_dir(dirname(__FILE__) . "/local/Tmpl/-"); set_include_dir(dirname(__FILE__) . "/-"); set_include_dir(dirname(__FILE__) . "/phpjasper/-");
<?php $void_framming = "yes"; require_once 'Lib/lib_PDF.php'; require_once "Informes.php"; set_include_dir(dirname(__FILE__) . "/../Cursos/-"); class PDF_Rotate extends FPDF { var $angle = 0; function Rotate($angle, $x = -1, $y = -1) { if ($x == -1) { $x = $this->x; } if ($y == -1) { $y = $this->y; } if ($this->angle != 0) { $this->_out('Q'); } $this->angle = $angle; if ($angle != 0) { $angle *= M_PI / 180; $c = cos($angle); $s = sin($angle); $cx = $x * $this->k; $cy = ($this->h - $y) * $this->k; $this->_out(sprintf('q %.5f %.5f %.5f %.5f %.2f %.2f cm 1 0 0 1 %.2f %.2f cm', $c, $s, -$s, $c, $cx, $cy, -$cx, -$cy)); } } function _endpage()