补充资料
这个是单独指定版快HIDE隐藏单个版快代码,我想让它增加些判断可以实现选择多个版快隐藏附件怎么增加判断语句?谢谢
复制内容到剪贴板
代码:
$allowgetattach = !empty($forum['allowgetattach']) || ($allowgetattach && !$forum['getattachperm']) || forumperm($forum['getattachperm']);
if ($fid == 56) { //把56改成你需要设置需要回复才能下载附件的版块fid
if ($isreply == 0) {
$isreplyquery = $db->query("SELECT pid FROM {$tablepre}posts WHERE tid='$tid' AND authorid='$discuz_uid' LIMIT 1");
$isreply = $db->result($isreplyquery, 0) ? 2 : 1;
}
$attach['hide'] = $isreply == 1 ? TRUE : FALSE;
$attach['description'] = substr($attach['description'], 6);
} else {
$attach['hide'] = FALSE;
}