• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP get_color函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中get_color函数的典型用法代码示例。如果您正苦于以下问题:PHP get_color函数的具体用法?PHP get_color怎么用?PHP get_color使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了get_color函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: get_color

            }
            $i++;
        }
        echo "\t" . 'color: ' . $color['color_hex'] . ';' . "\r\n}\r\n";
    }
}
?>
		::selection{
			background-color: <?php 
echo get_color('selection');
?>
;
		}
		::-moz-selection{
			background-color: <?php 
echo get_color('selection');
?>
;
		}
		/*#contentwrap{
			background-color:<?php 
echo $GLOBALS['site_layout']['contentbg_color'];
?>
 !important;
		}*/
/*		.mobile, ul.side-nav, slide-out, .title, .jssorb01 div:hover, .jssorb01 .av:hover, jssora05l, jssora05r{
			background-color: #FFFFFF;
		}*/
		/*.mobile, ul.side-nav, slide-out, .blogtitle{
			background-color:<?php 
echo $GLOBALS['site_layout']['accent_color'];
开发者ID:johnsondelbert1,项目名称:prj-illuminate,代码行数:31,代码来源:begin_html.php


示例2: adminmsg

                !$db->inserttable(table('category_hunterjobs'), $setsqlarr) ? adminmsg("保存失败!", 0) : "";
                $num = $num + $db->affected_rows();
            }
        }
        //填写管理员日志
        write_log("后台成功添加猎头职位分类!本次添加了" . $num . "个分类", $_SESSION['admin_name'], 3);
    }
    $link[0]['text'] = "返回列表";
    $link[0]['href'] = '?act=hunter_jobs';
    makejs_classify();
    makejs_train_classify();
    adminmsg("添加成功!本次添加了" . $num . "个分类", 2, $link);
} elseif ($act == 'colorlist') {
    get_token();
    $smarty->assign('navlabel', "color");
    $smarty->assign('color', get_color());
    $smarty->display('category/admin_color.htm');
} elseif ($act == 'add_color') {
    get_token();
    $smarty->assign('navlabel', "color");
    $smarty->display('category/admin_color_add.htm');
} elseif ($act == 'add_color_save') {
    check_token();
    $setsqlarr['value'] = !empty($_POST['val']) ? trim($_POST['val']) : adminmsg("请选择颜色", 1);
    $link[0]['text'] = "颜色列表";
    $link[0]['href'] = '?act=colorlist';
    $link[1]['text'] = "继续添加颜色";
    $link[1]['href'] = "?act=add_color";
    //填写管理员日志
    write_log("后台添加颜色分类!", $_SESSION['admin_name'], 3);
    $db->inserttable(table('color'), $setsqlarr) ? adminmsg("添加成功!", 2, $link) : adminmsg("添加失败!", 0);
开发者ID:winiceo,项目名称:fenzhan,代码行数:31,代码来源:admin_category.php


示例3: get_color

 if ($last_modified_id == $arr['id']) {
     echo ' last_modified';
 }
 echo "' height='36'>" . $arr['id'] . "</td>";
 echo "<td class='list'><span class='number'>" . $arr['number'] . "</span> <div style='float:right'><span class='shift_ch' data-direction='1'>&darr;</span> <span class='shift_ch' data-direction='-1'>&uarr;</span></div></td>";
 echo "<td class='list'>" . $arr['service_id'] . "</td>";
 echo "<td class='list'>";
 echo '<table cellpadding="0" cellspacing="0">';
 echo '<tr>';
 echo '<td>';
 if ($ch_logo = Itv::getLogoUriById(intval($arr['id']), 120)) {
     echo '<img src ="' . $ch_logo . '"/ >';
 }
 echo '</td>';
 echo '<td>';
 echo '<b style="color:' . get_color($arr) . '" title="' . get_hint($arr) . '">' . $arr['name'] . '</b>';
 echo '</td>';
 echo '</tr>';
 echo '</table>';
 echo "</td>";
 echo "<td class='list'>" . $arr['cmd'] . "</td>";
 echo "<td class='list'>" . $arr['xmltv_id'] . "</td>";
 echo "<td class='list'>" . (!empty($arr['genres_name']) ? _($arr['genres_name']) : '----') . "</td>";
 echo "<td class='list' align='center'>" . ($arr['enable_tv_archive'] == 1 ? '&bull;' : '') . "</td>";
 echo "<td class='list'>" . $arr['volume_correction'] . "</td>";
 echo "<td class='list' align='center'>\n";
 if (Admin::isActionAllowed()) {
     echo "<a href='#' onclick='if(confirm(\"" . _('Do you really want to reset claims counter?') . "\")){document.location=\"claims.php?reset=1&media_id=" . $arr['media_id'] . "&media_type=" . $arr['media_type'] . "\"}'>";
 }
 echo "<span style='color:red;font-weight:bold'>" . $arr['video_counter'] . " / " . $arr['sound_counter'] . " / " . $arr['no_epg'], " / " . $arr['wrong_epg'] . "</span>";
 if (Admin::isActionAllowed()) {
开发者ID:Rockystar2,项目名称:stalker_portal,代码行数:31,代码来源:add_itv.php


示例4: get_color

    </tr>
    <tr>
      <td width="10" height="20">&nbsp;</td>
      <td height="10"><font color="#FF3300">套餐内' . $promotion["cat_name"] . '总条数:
			  ' . $data["total_num"] . '条</font></td>
    </tr>
    <tr>
      <td width="10" height="20">&nbsp;</td>
      <td height="10"><font color="#FF3300">套餐内' . $promotion["cat_name"] . '剩余:
			   ' . $data["num"] . '条</font></td>
    </tr><tr>
      <td width="20" height="10">&nbsp;</td>
      <td height="10"><font color="#FF3300">推广方案:' . $promotion["cat_name"] . '<font></td>
    </tr>';
            if ($promotion["cat_id"] == 4) {
                $color = get_color();
                $html .= '<tr>
					<td align="right"></td>
					<td>
					选择颜色:
					</td>
				  </tr><tr>
					<td align="right"></td>
					<td>
						<input id="val" name="val" type="text" value="" class="input_text_100"/><div style="width:220px;" class="color_picker">';
                foreach ($color as $key => $value) {
                    $html .= '<div class="icolor" value="' . trim($value["value"], "#") . '" style="cursor:pointer;float:left; background-color: ' . $value["value"] . ';height:20px; width:30px;font-size:0px;margin:1px;"></div>';
                }
                $html .= '</div>
					</td>
				  </tr>';
开发者ID:dalinhuang,项目名称:yy,代码行数:31,代码来源:ajax_get_promotion.php


示例5: tc_rating_color_function

function tc_rating_color_function($atts, $content = null)
{
    extract(shortcode_atts(array("score" => ""), $atts));
    return get_color($score);
}
开发者ID:thabofletcher,项目名称:tc-site,代码行数:5,代码来源:tc_rating_color.php


示例6: sprintf

     $this_device_disp--;
     break;
 case 'GustStrength':
     if (!isset($datam['dashboard']['GustStrength'])) {
         break;
     }
     if (is_null($datam['dashboard']['GustStrength'])) {
         break;
     }
     if ($unitmetric == 0) {
         $speed = sprintf(__('%skm/h'), round((int) $datam['dashboard']['GustStrength']));
     } else {
         $speed = sprintf(__('%smph'), round((int) $datam['dashboard']['GustStrength'] * 0.621371));
     }
     echo '<tr><th valign="top">' . __('Gust Strength') . '</th><td valign="top" style="color:';
     echo get_color((int) $datam['dashboard']['GustStrength'], 0, 100, 0, 255, 0, 255, 0, 0) . '">';
     echo $speed;
     echo '</td></tr>';
     $this_device_disp--;
     break;
 case 'GustAngle':
     if (!isset($datam['dashboard']['GustAngle'])) {
         break;
     }
     if (is_null($datam['dashboard']['GustAngle'])) {
         break;
     }
     echo '<tr><th valign="top">' . __('Gust Angle') . '</th><td valign="top">';
     echo sprintf(__('%s°'), $datam['dashboard']['GustAngle']);
     echo '</td></tr>';
     $this_device_disp--;
开发者ID:potskymac,项目名称:Netatmo,代码行数:31,代码来源:index_combined.php


示例7: print_post

function print_post($para_print_post, $cate_slug)
{
    $approveCom = wp_count_comments($para_print_post['id']);
    $output .= '<article class="newsCenter" id="post-' . $para_print_post['id'] . '" style="border-top: 2px solid ' . get_color($cate_slug) . ';">';
    $output .= '<div class="autNewsCt row">';
    $output .= '<div class="top-box-article"> ';
    $output .= '<span class="ctnAutCt col-md-10 col-sm-10 col-xs-9 col-lg-5">';
    $output .= '<h4>';
    $output .= '<a href="' . $para_print_post['link'] . '">' . $para_print_post['title'] . '</a>';
    $output .= '</h4>';
    $output .= '</span>';
    $output .= '<a class="date-post" href="' . $para_print_post['link'] . '">' . $para_print_post['date'] . '</a>';
    $output .= '<div class="icon-list-btn col-lg-4">';
    $output .= '<ul>';
    $output .= '<li>';
    $output .= '<span title="Cảm ơn"><i class="fa fa-heart"></i></span>';
    $output .= '<br/>';
    $output .= '<span class="value-btn">' . getPostLoves($para_print_post['id']) . '</span>';
    $output .= '</li>';
    $output .= '<li>';
    $output .= '<a title="Chia sẻ" class="btn-shareface" data-gtmname="chia-se" rel="nofollow" target="_blank" href="http://www.facebook.com/sharer.php?u=' . $para_print_post['link'] . '">';
    $output .= '<span><i class="fa fa-share-alt"></i></span>';
    $output .= '<br/>';
    $output .= '<span class="value-btn">' . get_post_shares($para_print_post['id']) . '</span>';
    $output .= '</a>';
    $output .= '</li>';
    $output .= '<li>';
    $output .= '<span title="Lượt xem" ><i class="fa fa-eye"></i></i></span>';
    $output .= '<br/>';
    $output .= '<span class="value-btn">' . getPostViews($para_print_post['id']) . '</span>';
    $output .= '</li>';
    $output .= '</ul>';
    $output .= '</div>';
    $output .= '</div>';
    $output .= '<div class="bottom-box-article">';
    $output .= '<a class="link-post-content" href="' . $para_print_post['link'] . '">';
    $output .= '<p>' . $para_print_post['except'] . '</p>';
    $output .= '</a>';
    $output .= '<div class="imgArtCt">';
    $output .= '<em>';
    $output .= '<a href="' . $para_print_post['link'] . '"><img src="' . $para_print_post['image_link'] . '" alt="' . $para_print_post['title'] . '"></a>';
    $output .= '</em>';
    $output .= '</div>';
    $output .= '</div>';
    $output .= '</div>';
    $output .= '</article>';
    echo $output;
}
开发者ID:RobertDuy,项目名称:demo_to_client,代码行数:48,代码来源:functions.php


示例8: drawMapLabels


//.........这里部分代码省略.........
        $mapHosts = zbx_toHash($mapHosts, 'hostid');
    }
    // draw
    foreach ($selements as $selementId => $selement) {
        if (empty($selement) || $selement['label_type'] == MAP_LABEL_TYPE_NOTHING) {
            continue;
        }
        $elementInfo = $mapInfo[$selementId];
        $hl_color = null;
        $st_color = null;
        if (!isset($_REQUEST['noselements']) && $map['highlight'] % 2 == SYSMAP_HIGHLIGHT_ON) {
            if ($elementInfo['icon_type'] == SYSMAP_ELEMENT_ICON_ON) {
                $hl_color = true;
            }
            if ($elementInfo['icon_type'] == SYSMAP_ELEMENT_ICON_MAINTENANCE) {
                $st_color = true;
            }
            if ($elementInfo['icon_type'] == SYSMAP_ELEMENT_ICON_DISABLED) {
                $st_color = true;
            }
        }
        if (in_array($selement['elementtype'], [SYSMAP_ELEMENT_TYPE_HOST_GROUP, SYSMAP_ELEMENT_TYPE_MAP]) && !is_null($hl_color)) {
            $st_color = null;
        } elseif (!is_null($st_color)) {
            $hl_color = null;
        }
        $labelLocation = is_null($selement['label_location']) || $selement['label_location'] < 0 ? $map['label_location'] : $selement['label_location'];
        $label = [];
        if ($selement['label_type'] == MAP_LABEL_TYPE_IP && $selement['elementtype'] == SYSMAP_ELEMENT_TYPE_HOST) {
            $interface = reset($mapHosts[$selement['elementid']]['interfaces']);
            $label[] = ['msg' => $interface['ip']];
            $label = array_merge($label, $statusLines[$selementId]);
        } elseif ($selement['label_type'] == MAP_LABEL_TYPE_STATUS) {
            $label = $statusLines[$selementId];
        } elseif ($selement['label_type'] == MAP_LABEL_TYPE_NAME) {
            $label[] = ['msg' => $elementInfo['name']];
            $label = array_merge($label, $statusLines[$selementId]);
        } else {
            $label = array_merge($labelLines[$selementId], $statusLines[$selementId]);
        }
        if (empty($label)) {
            continue;
        }
        $w = 0;
        foreach ($label as $str) {
            $dims = imageTextSize(8, 0, $str['msg']);
            $w = max($w, $dims['width']);
        }
        $h = count($label) * $labelFontHeight;
        $x = $selement['x'];
        $y = $selement['y'];
        $image = get_png_by_selement($elementInfo);
        $iconX = imagesx($image);
        $iconY = imagesy($image);
        if (!is_null($hl_color)) {
            $icon_hl = 14;
        } elseif (!is_null($st_color)) {
            $icon_hl = 6;
        } else {
            $icon_hl = 2;
        }
        switch ($labelLocation) {
            case MAP_LABEL_LOC_TOP:
                $y_rec = $y - $icon_hl - $h - 6;
                $x_rec = $x + $iconX / 2 - $w / 2;
                break;
            case MAP_LABEL_LOC_LEFT:
                $y_rec = $y - $h / 2 + $iconY / 2;
                $x_rec = $x - $icon_hl - $w;
                break;
            case MAP_LABEL_LOC_RIGHT:
                $y_rec = $y - $h / 2 + $iconY / 2;
                $x_rec = $x + $iconX + $icon_hl;
                break;
            case MAP_LABEL_LOC_BOTTOM:
            default:
                $y_rec = $y + $iconY + $icon_hl;
                $x_rec = $x + $iconX / 2 - $w / 2;
        }
        $increasey = 12;
        foreach ($label as $line) {
            if (zbx_empty($line['msg'])) {
                continue;
            }
            $str = str_replace("\r", '', $line['msg']);
            $color = isset($line['color']) ? $line['color'] : $graphtheme['textcolor'];
            $dims = imageTextSize(8, 0, $str);
            if ($labelLocation == MAP_LABEL_LOC_TOP || $labelLocation == MAP_LABEL_LOC_BOTTOM) {
                $x_label = $x + ceil($iconX / 2) - ceil($dims['width'] / 2);
            } elseif ($labelLocation == MAP_LABEL_LOC_LEFT) {
                $x_label = $x_rec + $w - $dims['width'];
            } else {
                $x_label = $x_rec;
            }
            imagefilledrectangle($im, $x_label - 1, $y_rec + $increasey - $labelFontHeight + $labelFontBaseline, $x_label + $dims['width'] + 1, $y_rec + $increasey + $labelFontBaseline, get_color($im, $graphtheme['backgroundcolor']));
            imagetext($im, 8, 0, $x_label, $y_rec + $increasey, get_color($im, $color), $str);
            $increasey += $labelFontHeight + 1;
        }
    }
}
开发者ID:jbfavre,项目名称:debian-zabbix,代码行数:101,代码来源:maps.inc.php


示例9: drawRectangle

 public function drawRectangle($x1, $y1, $x2, $y2, $color)
 {
     imagerectangle($this->canvas, $x1, $y1, $x2, $y2, get_color($this->canvas, $color));
 }
开发者ID:jbfavre,项目名称:debian-zabbix,代码行数:4,代码来源:CCanvas.php


示例10: imageVerticalMarks

/**
 * Draw trigger recent change markers.
 *
 * @param resource $im
 * @param int      $x
 * @param int      $y
 * @param int      $offset
 * @param string   $color
 * @param string   $marks	"t" - top, "r" - right, "b" - bottom, "l" - left
 */
function imageVerticalMarks($im, $x, $y, $offset, $color, $marks)
{
    $polygons = 5;
    $gims = ['t' => [0, 0, -6, -6, -3, -9, 3, -9, 6, -6], 'r' => [0, 0, 6, -6, 9, -3, 9, 3, 6, 6], 'b' => [0, 0, 6, 6, 3, 9, -3, 9, -6, 6], 'l' => [0, 0, -6, 6, -9, 3, -9, -3, -6, -6]];
    foreach ($gims['t'] as $num => $px) {
        if ($num % 2 == 0) {
            $gims['t'][$num] = $px + $x;
        } else {
            $gims['t'][$num] = $px + $y - $offset;
        }
    }
    foreach ($gims['r'] as $num => $px) {
        if ($num % 2 == 0) {
            $gims['r'][$num] = $px + $x + $offset;
        } else {
            $gims['r'][$num] = $px + $y;
        }
    }
    foreach ($gims['b'] as $num => $px) {
        if ($num % 2 == 0) {
            $gims['b'][$num] = $px + $x;
        } else {
            $gims['b'][$num] = $px + $y + $offset;
        }
    }
    foreach ($gims['l'] as $num => $px) {
        if ($num % 2 == 0) {
            $gims['l'][$num] = $px + $x - $offset;
        } else {
            $gims['l'][$num] = $px + $y;
        }
    }
    $color = get_color($im, $color);
    $polygon_color = get_color($im, '960000');
    if (strpos($marks, 't') !== false) {
        imagefilledpolygon($im, $gims['t'], $polygons, $color);
        imagepolygon($im, $gims['t'], $polygons, $polygon_color);
    }
    if (strpos($marks, 'r') !== false) {
        imagefilledpolygon($im, $gims['r'], $polygons, $color);
        imagepolygon($im, $gims['r'], $polygons, $polygon_color);
    }
    if (strpos($marks, 'b') !== false) {
        imagefilledpolygon($im, $gims['b'], $polygons, $color);
        imagepolygon($im, $gims['b'], $polygons, $polygon_color);
    }
    if (strpos($marks, 'l') !== false) {
        imagefilledpolygon($im, $gims['l'], $polygons, $color);
        imagepolygon($im, $gims['l'], $polygons, $polygon_color);
    }
}
开发者ID:jbfavre,项目名称:debian-zabbix,代码行数:61,代码来源:graphs.inc.php


示例11: get_row_color

			<th class="text-center">Screw</th>
			<th class="text-center">Instructions</th>
		</tr>
	</thead>
		
	<tbody>
	<?php 
for ($i = 0; $i < 4; $i++) {
    ?>
		
		<tr class="<?php 
    echo get_row_color($screws[$i]['s']);
    ?>
">
			<td class="text-center"><span class="badge  badge <?php 
    echo get_color($screws[$i]['s']);
    ?>
"><?php 
    echo $i + 1;
    ?>
</span></td>
			<td><strong><?php 
    echo get_rotation_number($screws[$i]['t']);
    ?>
 <?php 
    echo get_direction($screws[$i]['s']);
    ?>
</strong></td>
		</tr>
	<?php 
}
开发者ID:kino3d,项目名称:FAB-UI,代码行数:31,代码来源:bed_calibration.php


示例12: getColor

 public function getColor($color, $alfa = 50)
 {
     if (isset($this->colors[$color])) {
         return $this->colors[$color];
     }
     return get_color($this->im, $color, $alfa);
 }
开发者ID:jbfavre,项目名称:debian-zabbix,代码行数:7,代码来源:CGraphDraw.php


示例13: get_color

     if ($person["PRIMARY_ROLE"] == $person["SECONDARY_ROLE"]) {
         $rpoints[2] = $right_edge - $base_width * 11;
         $rpoints[4] = $right_edge - $base_width * 10;
         $rpoints[10] = $right_edge - 3 * $base_width;
         $rpoints[12] = $right_edge - 2 * $base_width;
     }
     /* don't display the outline if the person has no role */
     if ($person["PRIMARY_ROLE"] != "Unknown") {
         $color = get_color($person["PRIMARY_COLOR"]);
         $pdf->setcolor($color[0], $color[1], $color[2]);
         $pdf->polygon($lpoints, 8, 1);
         $color = get_text_color($person["PRIMARY_COLOR"]);
         $pdf->setcolor($color[0], $color[1], $color[2]);
         $role1Width = $pdf->getTextWidth(12, $person["PRIMARY_ROLE"]);
         $pdf->addText($left_edge + $base_width / 2, $top_edge - 12, 12, $person["PRIMARY_ROLE"]);
         $color = get_color($person["SECONDARY_COLOR"]);
         $pdf->setcolor($color[0], $color[1], $color[2]);
         $pdf->polygon($rpoints, 8, 1);
         $color = get_text_color($person["SECONDARY_COLOR"]);
         $pdf->setcolor($color[0], $color[1], $color[2]);
         $role2Width = $pdf->getTextWidth(12, $person["SECONDARY_ROLE"]);
         $pdf->addText($right_edge - $base_width / 2 - $role2Width, $bottom_edge + 6, 12, $person["SECONDARY_ROLE"]);
         $pdf->setcolor(0, 0, 0);
     }
 }
 if ($offsetRow == 0) {
     $offsetRow = 2;
     $pageCount++;
 } else {
     $offsetRow--;
 }
开发者ID:azeckoski,项目名称:az-php-sandbox,代码行数:31,代码来源:create_badge.php


示例14: str_replace

{
    $text = str_replace('$v', $value, $text);
    $text = str_replace('$t', $total, $text);
    $percentage_shown = round(100 * $fraction);
    if (!empty($display_percent_sign)) {
        $percentage_shown .= get_string('percent_symbol', 'local_elisreports');
    }
    $text = str_replace('$p', $total == 0 ? get_string('na', 'local_elisreports') : $percentage_shown, $text);
    $text = str_replace('$e', $total == 0 ? get_string('na', 'local_elisreports') : '', $text);
    return $text;
}
//determine the colors to use
$color_array = get_color($color, $color_defaults);
$text_color_array = get_color($text_color, $text_color_defaults);
$background_color_array = get_color($background_color, $background_color_defaults);
$border_color_array = get_color($border_color, $border_color_defaults);
//calculate how full the bar should be
if ($total == 0) {
    $fraction = 0;
} else {
    $fraction = $value / $total;
}
//set up the chart
$chart = new pChart($width + 2, $height + 2);
$chart->setGraphArea(0, 0, $width + 1, $height + 1);
//draw the static background
draw_rectangle($chart, 0, 0, $width + 1, $height + 1, $background_color_array);
//draw the bar for our actual value
if ($fraction > 0) {
    draw_rectangle($chart, 0, 0, 1 + round($fraction * $width), $height + 1, $color_array);
}
开发者ID:jamesmcq,项目名称:elis,代码行数:31,代码来源:horizontalbar.php


示例15: get_score

    for ($l = 1; $l <= sizeof($queries); $l++) {
        print '<tr>';
        print '<td>' . $queries[$l][0] . '</td>';
        $value = get_score($queries[$l][1]);
        if ($queries[$l][2] == 'date') {
            $date = new DateTime($value);
            $diff = $date->diff($now);
            $formula = 365 * $diff->format("%y") + 30 * $diff->format("%m") + $diff->format("%d");
            print '<td>' . $formula . ' days</td>';
            $formula = $formula - 365;
        } else {
            print '<td>' . $value . '</td>';
            $formula = calculate_string($queries[$l][2] . $value);
        }
        $formula = max(min($formula, 100), -100);
        print '<td align=right><font color=' . get_color($formula) . '>' . $formula . '</font></td>';
        $score += $formula;
        print '</tr>';
    }
    print '<tr><td><b><big>Total score</big></b></td><td colspan=2 align=right><b><big>' . $score . '</big></b></td></tr>';
    $mysqli->close();
    print '</table>';
}
function get_score($query)
{
    global $mysqli;
    $res = $mysqli->query($query);
    if ($res) {
        $res = $res->fetch_assoc();
        if ($res) {
            $res = current($res);
开发者ID:Krinkle,项目名称:xtools,代码行数:31,代码来源:adminscore.php


示例16: get_color

<div class="ibox-content">
<div class="panel-body">

<h5>

    <span > <i style="color:<?php 
echo get_color(1);
?>
;" class="fa fa-square"></i> <=3</span> || <span ><i style="color:<?php 
echo get_color(2);
?>
;" class="fa fa-square"></i>  >3 to <=6</span> || <span ><i  style="color:<?php 
echo get_color(3);
?>
;" class="fa fa-square"></i>  >6 to <=9</span> || <span ><i style="color:<?php 
echo get_color(4);
?>
;" class="fa fa-square"></i>  >9</span>

</h5>

<div class="col-lg-6">
    <div class="col-lg-6">
        <form class="form" method="post" action="<?php 
echo base_url();
?>
">
            <select name="date" class="form-control">
                <option selected>--SELECT PERIOD--</option>

                <?php 
开发者ID:Collinceselly,项目名称:hello-world,代码行数:31,代码来源:lab_welcome_message.php


示例17: imagecreate

} else {
    $im = imagecreate($sizeX + $shiftX + 61, $sizeY + $shiftYup + $shiftYdown + 10);
}
$graphtheme = ['theme' => 'blue-theme', 'textcolor' => '1F2C33', 'highlightcolor' => 'E33734', 'backgroundcolor' => 'FFFFFF', 'graphcolor' => 'FFFFFF', 'gridcolor' => 'CCD5D9', 'maingridcolor' => 'ACBBC2', 'gridbordercolor' => 'ACBBC2', 'nonworktimecolor' => 'EBEBEB', 'leftpercentilecolor' => '429E47', 'righttpercentilecolor' => 'E33734'];
$themes = DB::find('graph_theme', ['theme' => getUserTheme(CWebUser::$data)]);
if ($themes) {
    $graphtheme = $themes[0];
}
$black = get_color($im, '000000');
$green = get_color($im, '34AF67');
$red = get_color($im, 'D64E4E');
$grey = get_color($im, '969696', 50);
$backgroundcolor = get_color($im, $graphtheme['backgroundcolor']);
$gridcolor = get_color($im, $graphtheme['gridcolor']);
$textcolor = get_color($im, $graphtheme['textcolor']);
$highlightcolor = get_color($im, $graphtheme['highlightcolor']);
$x = imagesx($im);
$y = imagesy($im);
imagefilledrectangle($im, 0, 0, $x, $y, $backgroundcolor);
$d = zbx_date2str(_x('Y', DATE_FORMAT_CONTEXT));
$str = _s('%1$s (year %2$s)', $service['name'], $d);
$x = imagesx($im) / 2 - imagefontwidth(4) * mb_strlen($str) / 2;
imageText($im, 10, 0, $x, 14, $textcolor, $str);
$now = time(null);
$to_time = $now;
$count_now = [];
$problem = [];
$start = mktime(0, 0, 0, 1, 1, date('Y'));
$wday = date('w', $start);
if ($wday == 0) {
    $wday = 7;
开发者ID:jbfavre,项目名称:debian-zabbix,代码行数:31,代码来源:chart5.php


示例18: hexdec

        $b = hexdec(substr($hex, 4, 2));
    }
    return "rgba({$r}, {$g}, {$b}, {$alpha})";
}
$header_background_color = get_color('hb', '#eeeeee');
$header_text_color = get_color('ht', '#000000');
$header_link_color = get_color('hl', '#00554e');
$content_background_color = get_color('cb', '#ffffff');
$content_text_color = get_color('ct', '#000000');
$content_link_color = get_color('cl', '#00554e');
$sidebar_background_color = get_color('sb', '#ffffff');
$sidebar_text_color = get_color('st', '#000000');
$sidebar_link_color = get_color('sl', '#00554e');
$footer_background_color = get_color('fb', '#444444');
$footer_text_color = get_color('ft', '#ffffff');
$footer_link_color = get_color('fl', '#a1fff6');
?>
/* Header */
#masthead {
  background: <?php 
echo $header_background_color;
?>
;
  color: <?php 
echo $header_text_color;
?>
;
}

#masthead a,
#masthead a:visited {
开发者ID:CUUATS,项目名称:hovercraft,代码行数:31,代码来源:theme-colors.php


示例19: wp_nav_menu

					</object>
					</a>
                    
				</div>
				<div class="six push_three columns">
					<button id="mobilemenu">Menu</button>
					<?php 
wp_nav_menu(array('exclude' => 7));
?>
				</div>
			</div>
		</header>
		<?php 
global $post;
if ($post->post_parent == '15') {
    $hcolor = get_color(get_field("text_colour"));
    $hbackground = str_replace(" ", "-", get_field("background_colour"));
    // 	print "color<pre>";
    // 	print_r($hcolor);
    // 	print "</pre>";
    // 	print "background<pre>";
    // 	print_r($hbackground);
    // 	print "</pre>";
    $himage = get_field("head_image");
    if ($himage != "") {
        ?>
				<div class="container imageband <?php 
        echo $hbackground;
        ?>
" >
					<div class="row heading headingimage" style="background-image:url(<?php 
开发者ID:Jerram-Marketing,项目名称:Gummer-Co,代码行数:31,代码来源:header.php


示例20: generate_badge

function generate_badge($badges_lines, $style, $color, $output_badge)
{
    global $Styles, $Colors;
    foreach ($badges_lines as $line) {
        $line->font = $Styles[$style];
    }
    $y = 0;
    foreach ($badges_lines as $line) {
        $line->initiate($line->size, $line->angle, $line->font, $line->value);
        $y += $line->height;
        $line->y = $y;
    }
    $Image = new Text();
    $Image->width = WIDTH;
    $Image->height = $y;
    $img = imagecreatetruecolor($Image->width, $Image->height);
    imagealphablending($img, FALSE);
    imagesavealpha($img, TRUE);
    foreach ($badges_lines as $line) {
        $line->color = imagecolorallocate($img, get_color("r", $Colors[$color]), get_color("g", $Colors[$color]), get_color("b", $Colors[$color]));
    }
    $transparent = imagecolorallocatealpha($img, 255, 255, 255, 127);
    imagefilledrectangle($img, 0, 0, $Image->width, $Image->height, $transparent);
    foreach ($badges_lines as $line) {
        imagettftext($img, $line->size, $line->angle, $line->x, $line->y, $line->color, $line->font, $line->value);
    }
    imagepng($img, $output_badge);
    imagedestroy($img);
}
开发者ID:blaxter,项目名称:lastfm-badges,代码行数:29,代码来源:Badges.php



注:本文中的get_color函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP get_colored_device_status函数代码示例发布时间:2022-05-15
下一篇:
PHP get_collection_resources函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap