Home > CMS Tutorial > DEDECMS > body text

Dreamweaver dedecms TAG tag cannot find and implement color tag method

(*-*)浩
Release: 2019-12-03 15:03:40
Original
1964 people have browsed it

Dreamweaver dedecms TAG tag cannot find and implement color tag method

TAG page cannot find the solution to the problem of tags When we click on a tag on the tags.php page, sometimes it will prompt: "The system does not have this tag, it may have been removed!"

But we check the background of the program and the page displayed in the foreground. This label does exist, what if this problem is solved?

Solution:

There is a tags.php file in the root directory of the Dedecms program

Open this file:

Find $tag = FilterSearch(urldecode($tag));

Change to $tag = urldecode($tag);

to solve this problem.

dedeTAG color label production method:

1. Add the following function to /include/common.func.php

function getTagStyle() 

{ 

$minFontSize=8; //最小字体大小,可根据需要自行更改 

$maxFontSize=18; //最大字体大小,可根据需要自行更改 

return 'font-size:'.($minFontSize+lcg_value()*(abs($maxFontSize-$minFontSize))).'px; 

color:#'.dechex(rand(0,255)).dechex(rand(0,196)).dechex(rand(0,255)); 

}
Copy after login

2 .Use the following code in the template to call the tag

{dede:tag row='45' getall='1' sort='hot'} 
 
<a href=&#39;[field:link/]&#39; title="[field:tag /]([field:total /])" style="[field:total runphp=yes]@me=getTa 
gStyle();[/field:total]">[field:tag /]</a> 
 
{/dede:tag}
Copy after login

The above is the detailed content of Dreamweaver dedecms TAG tag cannot find and implement color tag method. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template