Ejemplo n.º 1
0
    imageline($img, 65, $z * $namespace + 18, 75, $z * $namespace + 18, $userx['color']);
    imagestring($img, 2, 80 + 1, $z * $namespace + 12, $userx['name'], $c[bg]);
    imagestring($img, 2, 80, $z * $namespace + 11, $userx['name'], $userx['color']);
    $z++;
}
foreach ($xdata as $k => $v) {
    $xdata2[$k - 13697] = $v / 1;
}
if (false) {
    print "<pre>days = {$days} \n\n\n";
    print_r($data);
    print "\n\n------------------------\n\n";
    print_r($xdata2);
    die;
}
drawdata($xdata2, $users[-1]['color']);
Header('Content-type:image/png');
ImagePNG($img);
ImageDestroy($img);
function drawdata($p, $color)
{
    global $days, $scalex, $m, $img;
    $oldy = $m;
    for ($i = 0; $i < $days; $i++) {
        $y = $m - $p[$i];
        $x = $i * $scalex;
        if (!$p[$i]) {
            $y = $oldy;
        }
        imageline($img, $x, $oldy, $x + $scalex - 1, $y, $color);
        $oldy = $y;
Ejemplo n.º 2
0
            $sql = "SELECT {$fielddata} FROM {$drg->tb_proc_codes} WHERE code {$sql_LIKE} '{$parentcode}%'";
            $lines = $db->SelectLimit($sql, 1);
            if ($lines) {
                if ($lines->RecordCount()) {
                    //mysql_data_seek($lines,0);
                    $priocolor = 1;
                    //echo "hello";
                    $parentdata = $lines->FetchRow();
                    drawdata($parentdata, $zeile);
                    $parent[$parentcode] = 1;
                    $priocolor = 0;
                    //echo "hello";
                }
            }
        }
        drawdata($zeile, $advzeile);
        //$idx++;
        echo "</tr>";
        $priocolor = 0;
        $iscolor = 0;
    }
}
?>

</table>
<?php 
if (!$showonly && $linecount > 0) {
    ?>
<input type="hidden" name="lastindex" value="<?php 
    echo $idx;
    ?>
Ejemplo n.º 3
0
    imageline($img, 65, $z * $namespace + 18, 75, $z * $namespace + 18, $userx['color']);
    imagestring($img, 2, 80 + 1, $z * $namespace + 12, $userx['name'], $c[bg]);
    imagestring($img, 2, 80, $z * $namespace + 11, $userx['name'], $userx['color']);
    $z++;
}
foreach ($xdata as $k => $v) {
    $xdata2[$k - 13697] = $v * 5;
}
if (0) {
    print "<pre>days = {$days} \n\n\n";
    print_r($data);
    print "\n\n------------------------\n\n";
    print_r($xdata2);
    die;
}
drawdata($xdata2, $users[-1]['color'], true, $users[-1]['color'] + 0x40000000);
Header('Content-type:image/png');
ImagePNG($img);
ImageDestroy($img);
function drawdata($p, $color, $derp = false, $color2 = false)
{
    global $days, $scalex, $m, $img, $xs;
    $oldy = $m;
    if ($derp) {
        $points[] = 0;
        $points[] = $m - 1;
    }
    for ($i = 0; $i < $days; $i++) {
        $y = $m - $p[$i];
        $x = $i * $scalex;
        if (!$p[$i]) {
Ejemplo n.º 4
0
			<input type="hidden" name="' . $hidselector . $idx . '" value="' . $data['code_parent'] . '">';
    $idx++;
    echo '
	</td>
	<td><font face=arial size=2><nobr>';
    echo $data['code'] . '&nbsp;';
    echo '&nbsp;</nobr></td><td>&nbsp;';
    echo '<font face=arial size=2>';
    echo $data['parent_desc'] . ':<b>' . $data['description'] . '</b>&nbsp;';
    echo '</td>';
    echo '</tr>';
}
if ($linecount) {
    $idx = 0;
    while ($qlist = $qlist_obj->FetchRow()) {
        drawdata($qlist);
        //$idx++;
    }
}
?>

</table>
<?php 
if ($linecount > 0) {
    ?>
<input type="hidden" name="lastindex" value="<?php 
    echo $idx;
    ?>
">
<input type="submit" value="<?php 
    echo $LDApplySelection;
Ejemplo n.º 5
0
    ?>
</nobr></b>&nbsp;</td>

<td colspan=7><font face=arial size=2 color=#ffffff>&nbsp;&nbsp;&nbsp;<b><?php 
    echo $LDDescription;
    ?>
</b>
</td>
		
</tr>
<?php 
    $selector = 'ops';
    $hidselector = 'ops_px';
    /* Draw the procedure codes */
    while ($procedure = $proc_obj->FetchRow()) {
        drawdata($procedure);
    }
    $proc_exists = true;
} else {
    ?>
<input type="hidden" name="ops0" value="">
<?php 
    $proc_exists = false;
}
?>
</table>
<input type="hidden" name="last_ops_index" value="<?php 
echo $idx;
?>
">
<?php 
Ejemplo n.º 6
0
    imagestring($img, 3, 2, $m - $i * 100 + 50, ($i * 100 - 50) * $scaley, $c['mk1']);
}
$users = array();
$userq = $sql->query("SELECT id, name FROM `users` ORDER BY `posts` DESC LIMIT 0, 10");
while ($u = $sql->fetch($userq)) {
    $users[$u['id']] = array('name' => $u['name'], 'color' => imagecolorallocate($img, rand(100, 255), rand(100, 255), rand(100, 255)));
}
$z = count($users);
$namespace = 12;
imagerectangle($img, 61, 11, 174, 15 + $z * $namespace, $c['bg']);
imagefilledrectangle($img, 60, 10, 173, 14 + $z * $namespace, $c['bg2']);
imagerectangle($img, 60, 10, 173, 14 + $z * $namespace, $c['mk2']);
$z = 0;
$data = getdata(array_keys($users));
foreach ($users as $uid => $userx) {
    drawdata($data[$uid], $userx['color']);
    imageline($img, 66, $z * $namespace + 19, 76, $z * $namespace + 19, $c['bg']);
    imageline($img, 65, $z * $namespace + 18, 75, $z * $namespace + 18, $userx['color']);
    imagestring($img, 2, 80 + 1, $z * $namespace + 12, $userx['name'], $c['bg']);
    imagestring($img, 2, 80, $z * $namespace + 11, $userx['name'], $userx['color']);
    $z++;
}
/*	if($_GET['debugsql']) {
		require 'lib/layout.php';
		print $header.$footer;
		printtimedif(time());
		die(1);
	} */
Header('Content-type:image/png');
ImagePNG($img);
ImageDestroy($img);
Ejemplo n.º 7
0
    }
    if ($data[notes]) {
        echo '&nbsp;<a href="javascript:ssm(\'n_' . cleandata($data['code']) . '\');"><img ' . $img['info'] . ' alt="' . $LDNotes . '"></a>';
        drawAdditional("n", $data['code'], $data[notes], "ffcc99", $LDNotes);
    }
    if ($data[remarks]) {
        echo '&nbsp;<a href="javascript:ssm(\'r_' . cleandata($data['code']) . '\');"><img ' . $img['bubble'] . ' alt="' . $LDRemarks . '"></a>';
        drawAdditional("r", $data['code'], $data[remarks], "cceeff", $LDRemarks);
    }
    echo '</td>';
    echo "</tr>";
}
if ($drg) {
    $idx = 0;
    while ($row = $drg->FetchRow()) {
        drawdata($row);
    }
}
?>

</table>
<?php 
if (!$showonly && $linecount > 0) {
    ?>
<input type="hidden" name="lastindex" value="<?php 
    echo $idx;
    ?>
">
<input type="submit" value="<?php 
    echo $LDApplySelection;
    ?>