Home >CMS Tutorial >PHPCMS >How to modify phpcms navigation link

How to modify phpcms navigation link

angryTom
angryTomOriginal
2020-02-11 17:21:493012browse

How to modify phpcms navigation link

How to modify the phpcms navigation link

There are two ways to change the phpcms navigation link:

1. In the background Add a column by using an external link. Fill in the link address yourself and set it to be displayed in the navigation bar. If the position is wrong, you can set the sorting.

2. Modify the code and manually fill in the navigation code. The file path is: \phpcms\templates\default\content\header.html

The specific location is:

{pc:content action="category" catid="0" num="25" siteid="$siteid" order="listorder ASC"}
    <ul class="nav-site">
    <li><a href="{siteurl($siteid)}"><span>首页</span></a></li>
    {loop $data $r}
    <li class="line">|</li>
    <li><a href="{$r[url]}"><span>{$r[catname]}</span></a></li>
    {/loop}
    </ul>
{/pc}

Yes Replace {$r[url]} in the li tag with any link address, and {$r[catname]} with the name on the navigation.

Related recommendations: phpcms tutorial

The above is the detailed content of How to modify phpcms navigation link. For more information, please follow other related articles on the PHP Chinese website!

Statement:
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