Home CMS Tutorial DEDECMS What should I do if the dede search keyword/tag label cannot distinguish between uppercase letters?

What should I do if the dede search keyword/tag label cannot distinguish between uppercase letters?

Dec 27, 2019 am 09:37 AM
dede

What should I do if the dede search keyword/tag label cannot distinguish between uppercase letters?

dede What should I do if the search keywords/tags cannot distinguish between uppercase letters?

DEDECMS When searching within the site, if the search term contains capital letters, it will be filtered out. There is also a bug that when accessing a tag containing capital letters, it will prompt that the tag does not exist

Recommended Study: CMMS

When we use the DEDECMS site to search, if the search terms contain capital letters, they will be filtered out, and when accessing tags containing capital letters, they will be filtered out. Prompt label does not exist bug. Before the official patch is released, you can use the strtolower() function to convert uppercase letters into lowercase letters for a temporary solution.

Specific modification method:

Open the tags.php file in the root directory of the website (to solve the problem of tags not being recognized in capital letters), and find the following line of code:

The code is as follows:

$tag = trim($_SERVER['QUERY_STRING']);
Copy after login

Replace the above code with the following code:

The code is as follows:

$tag = strtolower(trim($_SERVER['QUERY_STRING']));
Copy after login

Then open the /plus/search.php file (this is to modify the search problem), Find the following line of code:

The code is as follows:

$oldkeyword = $keyword = FilterSearch(stripslashes($keyword));
Copy after login

Replace the above code with the following code:

The code is as follows:

$oldkeyword = $keyword = FilterSearch(stripslashes(strtolower($keyword)));
Copy after login

End of code modification , so that when we search on the search page, no matter whether the input is uppercase or lowercase, it can be summarized in the current search results.

The above is the detailed content of What should I do if the dede search keyword/tag label cannot distinguish between uppercase letters?. For more information, please follow other related articles on the PHP Chinese website!

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

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
4 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
4 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. How to Fix Audio if You Can't Hear Anyone
4 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
WWE 2K25: How To Unlock Everything In MyRise
1 months ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)