Archive for the ‘dedecms’ Category
曾经最欣赏的DEDE现在呢
星期六, 七月 12th, 2008今天突然想到DEDE打开首页
(更多…)
DEDECMS5.1UTF8升级出错,无法访问后台
星期一, 四月 7th, 2008output started at /include/pub_charset.php:1)
出错信息提示
基本是围绕着这个.
官方论坛也有出现同样故障的难兄
Warning: session_start() [function.session-start]: Cannot send session cache limiter – headers already sent (output started at /www/users/doukoo.com/include/pub_charset.php:1) in /www/users/××××.com/include/inc_userlogin.php on line 3
Warning: Cannot modify header information – headers already sent by (output started at /www/users/××××.com/include/pub_charset.php:1) in /www/users/××××.com/dede/config.php on line 10
最终没有合理的答案
官方也没提供任何解答
最先遇到问题的地方在 后台首页
找了相关的PHP 出错信息
解决了这个问题。。
跟以前的WORDPRESS同样的问题
编码
PHP 不支持 带BOM的UTF-8
打开 pub_charset.php 保存为无BOM的版本就可以了
dedecms删除文章自动删除缩图和内容中大图
星期二, 三月 18th, 2008打开dede/inc/inc_batchup.php
找到”//删除数据库的内容”
在这前面加上
//删除缩略图
if($arcRow['litpic']!=”"){
$dsql->ExecuteNoneQuery(“Delete From #@__uploads where url=’$arcRow[litpic]‘”);
$truedir = GetTruePath($arcRow['siterefer'],$arcRow['sitepath']);
$litpicfile = $truedir.$arcRow['litpic'];
@unlink($litpicfile);
}
//删除大图
$arcbodyQuery = “Select * from “.$arcRow['addtable'].” where aid=’$aid’”;
$arcbodyRow = $dsql->GetOne($arcbodyQuery);
$imgsrcarray=GetImageSrc($arcbodyRow['body']);
foreach ($imgsrcarray as $v) {
if((trim($v)!=”")&&(!eregi(“^http://”,$v))){
$dsql->ExecuteNoneQuery(“Delete From #@__uploads where url=’$v’”);
$picfile = $truedir.$v;
@unlink($picfile);
}
}
//删除数据库的内容
第二处:
找到
Select #@__archives.ID,#@__archives.title,#@__archives.typeid
改为:
Select #@__archives.ID,#@__archives.title,#@__archives.typeid,#@__archives.litpic
第三处:
在文件最后加上一函数
//获得内容中的图像地址
function GetImageSrc($body){
if( !isset($body)) return ”;
else{
preg_match_all (“/<(img|IMG)(.*)(src|SRC)=[\"|'|]{0,}([h|\/].*(jpg|JPG|gif|GIF))[\"|'|\s]{0,}/isU”,$body,$out);
return $out[4];
}
}
dedecms的LOOP 标记规则
星期二, 三月 18th, 2008功能说明:用于调用任意表的数据,一般用于调用论坛贴子之类的操作
适用范围:所有模板
(1) 基本语法
{ dede:loop table=’ sort=” row=” if=” }
底层模板
{ dede:loop }
(2) 属性
[1] table 表示查询的数据表
[2] sort 用于排序的字段
[3] row 返回结果的条数
[4] if 查询条件
(3)底层模板变量
这个标记的底层模板变量即是被查询表的所有字段
DEDECMS调用DISCUZ论坛指定版块的方法
星期二, 三月 18th, 2008{ dede:loop table=”cdb_threads” if=”fid=1&line;&line;fid=2 and displayorder!=-1″ sort=”tid” row=”6″ }
<a href=”/bbs/viewthread dot php?tid=[field:tid /]” target=”_blank”>
·[field:subject function="cn_substr(' at me',50)" /]
</a>
<br/>
{ /dede:loop }
论坛置顶版块调用方法2:
{ dede:loop table=”cdb_threads” sort=”dateline” if=”fid=’3′ and typeid=’51′” row=”10″ }
<a href=”/a/bbs/viewthread dot php?tid=[field:tid /]” target=”_blank”>
·[field:subject function="cn_substr(' at me',30)" /]</a> <br>
{ /dede:loop }
DEDECMS调用DISCUZ论坛最新主题
星期二, 三月 18th, 2008论坛最新主题调用方法
代码
{ dede:loop table=”cdb_threads” sort=”tid” row=”10″ }
<a href=”/dz/viewthread.php?tid=[field:tid /]“>
·[field:subject function="cn_substr(' at me',30)" /]([field:lastpost function="date('m-d H:M','@me')" /])
</a>
<br/>
{ /dede:loop }
修改DEDE-RSSMAP连接路径
星期二, 三月 4th, 2008DEDE,rss路径修改
星期二, 三月 4th, 2008将RSS放到跟目录,而不是/PLUS/RSS
dedecms V5相关文章likeart,链接错误
星期五, 二月 15th, 2008dedecms V5相关文章likeart连接错误
原本连接都是指向html
现在变动态连接了..
怪不得收录怪怪的..
看来还不如V4
哎.
