Home> CMS Tutorial> PHPCMS> body text

How to determine whether it is the home page in phpcms

Release: 2020-01-13 17:29:49
Original
2588 people have browsed it

How to determine whether it is the home page in phpcms

Many times, if statements need to be used in the template to determine whether it is the homepage, so as to set the homepage and non-homepage codes.

In Phpcms V9, what is the code to determine whether it is the home page?

The specific code for Phpcms V9 to determine whether it is the homepage is:

{if !$catid}我是首页{/if}
Copy after login

The basis for judgment is:The $catid variable on the homepage is empty, so judging whether it has a value can determine whether it is the homepage.

PHP Chinese website, a large number of freePHPCMS tutorials, welcome to learn online!

The above is the detailed content of How to determine whether it is the home page in phpcms. 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
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!