---
title: "关于dedecms的一些问题修正总结"
author: "ausdin"
date: "2011-11-02T10:13:58Z"
tags: []
categories: ["Web前端"]
slug: "dedecms"
draft: false
lastmod: "2011-11-30T21:51:31Z"
id: 1229614
url: "https://ausdin.iteye.com/blog/1229614"
---

*注：文中含有连续的两个empty是由于系统bug引起
1. archives_do 无法全部去除文章属性：

```php

    /*
        dede/archives_do.php
        注释为空时 等于 旧属性
    */
    if(!empty($flag))
    {
        if(preg_match("#p#", $oldflag)) $flag .= ',p';
        if(preg_match("#j#", $oldflag)) $flag .= ',j';
    }
    /*
    else
    {
        $flag = $oldflag;
    }
    */

```


2.  栏目为外部链接时无法使用{cmspath}

```php

/*
    include/arc.listview.class.php
    修改：$gotourl = $this->Fields['typedir'];
*/
$gotourl = str_ireplace('{cmspath}', $GLOBALS['cfg_cmspath'], $this->Fields['typedir']);

```


3.  channelartlist 只能指定显示条数，而不能指定从哪一条开始，可将row属性改为limit属性

```php

/*
    include/taglib/channelartlist.lib.php
    修改：
    $totalnum = $row;
    if(empty($totalnum)) $totalnum = 20;
*/
if ( empty($limit) ) 
    $limit = "limit 20";
else    
    $limit = "limit $limit";

```