discuz中这样的sql如何写 discuz 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 某个板块下的可以显示的分类信息(可用)function get_threadclass($fid){ $threadtypes = C::t('forum_forumfield')->fetch($fid); $threadtypes = dunserialize($threadtypes['threadtypes']); foreach(C::t('forum_threadclass')->fetch_all_by_fid($fid) as $type) { if(isset($threadtypes['types'][$type['typeid']])) { $return[]=$type; } } return $return; } 好象我的表述有点问题:是这样我主要是想要帖子中的message字段里的信息,条件是该版块下的A子版块中的D主题分类的所有帖子中的message的内容我想了一下,好象是要用到pro_forum_post这个表及主题分类表pre_forum_threadclass因为pro_forum_post里面有message帖子内容信息的字段,而pre_forum_threadclass里面是主题分类的表,但是这两个表如何关联呢?我写了一个句子,查不出来,不知哪里错了。我是这样写的:SELECT sh_forum_post.message, sh_forum_post.fid FROM sh_forum_post, sh_forum_threadclass WHERE sh_forum_post.fid = 128 AND sh_forum_threadclass.`name` = '美丽图片' discuz中的表有一点很让人闹心,那就是很多表中的字段没有关联性,都是独立的,所以无法做出关系条件来 好象有点门,我是这样想的,论坛里默认的源码中,点那些主题分类就可以出现我要的效果,看来源码中就有这句sql那,他是怎么写的呢,它的地址是这样,帮我分析一下,谢谢你 jam00,http://127.0.0.1/forum.php?mod=forumdisplay&fid=129&filter=typeid&typeid=26 pre_forum_thread里的字段typeid就是分类信息的id PHP入门从何入手? ci框架session引用问题 centos释放内存的问题 cakephp2.21 安装时出错 求一段正则 \r \n的研究 帝国CMS整合PHPwind出问题了 EclipsePHP Studio3的怎么使用 自己网站代码加密~ 是否能解除360的拦截问题? php update 问题 注册页面出现Column count doesn't match value count at row 1 如何让数据显示不重复,只显示最新数据
function get_threadclass($fid){
$threadtypes = C::t('forum_forumfield')->fetch($fid);
$threadtypes = dunserialize($threadtypes['threadtypes']);
foreach(C::t('forum_threadclass')->fetch_all_by_fid($fid) as $type) {
if(isset($threadtypes['types'][$type['typeid']])) {
$return[]=$type;
}
}
return $return;
}
我主要是想要帖子中的message字段里的信息,条件是该版块下的A子版块中的D主题分类的所有帖子中的message的内容
我想了一下,好象是要用到pro_forum_post这个表及主题分类表pre_forum_threadclass因为pro_forum_post里面有message帖子内容信息的字段,而pre_forum_threadclass里面是主题分类的表,但是这两个表如何关联呢?我写了一个句子,查不出来,不知哪里错了。
我是这样写的:SELECT sh_forum_post.message, sh_forum_post.fid FROM sh_forum_post, sh_forum_threadclass WHERE sh_forum_post.fid = 128 AND sh_forum_threadclass.`name` = '美丽图片'
好象有点门,我是这样想的,论坛里默认的源码中,点那些主题分类就可以出现我要的效果,看来源码中就有这句sql
那,他是怎么写的呢,它的地址是这样,帮我分析一下,谢谢你 jam00,
http://127.0.0.1/forum.php?mod=forumdisplay&fid=129&filter=typeid&typeid=26