按照默认来吧,不要颜色了
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
<?php $show_title="$MSG_SOURCE - $OJ_NAME"; ?>
|
||||
<?php include("template/$OJ_TEMPLATE/header.php");?>
|
||||
<?php require_once('./include/const.inc.php');?>
|
||||
|
||||
<div class="padding">
|
||||
<div style="margin-top: 0px; margin-bottom: 14px; padding-bottom: 0px; " >
|
||||
@@ -21,23 +20,12 @@
|
||||
];
|
||||
|
||||
// 生成标签地图
|
||||
// 为标签添加颜色样式
|
||||
function colorize_tag($tag) {
|
||||
$color_theme=["default","primary","success","info","warning","danger"];
|
||||
$hash_num = hexdec(substr(md5($tag), 0, 7));
|
||||
$label_theme = $color_theme[$hash_num % count($color_theme)];
|
||||
|
||||
if ($label_theme == "")
|
||||
$label_theme = "default";
|
||||
|
||||
return $label_theme;
|
||||
}
|
||||
|
||||
foreach ($tag_map as $level => $tags): ?>
|
||||
<h3><a href="problemset.php?search=难度<?php echo $level; ?>">难度 <?php echo $level; ?></a></h3>
|
||||
<div class="tag-cloud">
|
||||
<?php foreach ($tags as $tag):
|
||||
$label_theme = colorize_tag($tag);
|
||||
$label_theme = "default";
|
||||
?>
|
||||
<a href="problemset.php?search=<?php echo urlencode($tag); ?>" class="ui <?php echo $label_theme; ?> label"><?php echo $tag; ?></a>
|
||||
<?php endforeach; ?>
|
||||
|
||||
Reference in New Issue
Block a user