summaryrefslogtreecommitdiff
path: root/includes/structure.inc
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2001-04-21 14:19:20 +0000
committerDries Buytaert <dries@buytaert.net>2001-04-21 14:19:20 +0000
commitcccb132c81e82cc01ca7f014d185c1ecce864377 (patch)
tree2814a3444025cc756968c6e273b65c6475c9012e /includes/structure.inc
parent3f1979aa3cfa2d50789e88bd0a857dec6babb44b (diff)
downloadbrdo-cccb132c81e82cc01ca7f014d185c1ecce864377.tar.gz
brdo-cccb132c81e82cc01ca7f014d185c1ecce864377.tar.bz2
- Addition: added a "promote" field to the node table, which
makes "promoting nodes" to the main page possible. Stories and reviews could be promoted by default, but - on accasion a good book entry could be manually promoted too. Thus all existing content types can be shown on the main page, not just stories. Requires a SQL update, see 2.00-to-x.xx.sql! - Addition: implemented "auto-post new submissions" feature to disable or by-pass the moderation queue in addition to "moderate new submissions". TODO: admin moderation versus registered user moderation. - Addition: added category and topic support to page.module.
Diffstat (limited to 'includes/structure.inc')
-rw-r--r--includes/structure.inc14
1 files changed, 13 insertions, 1 deletions
diff --git a/includes/structure.inc b/includes/structure.inc
index 94c14ad6d..aabb9d34a 100644
--- a/includes/structure.inc
+++ b/includes/structure.inc
@@ -50,7 +50,19 @@ function category_expire_threshold($cid) {
// return default comment status of category $cid:
function category_comment($cid) {
$category = category_get_object("cid", $cid);
- return $category->comment;
+ return $category->comment ? $category->comment : 0;
+}
+
+// return default promote status of category $cid:
+function category_promote($cid) {
+ $category = category_get_object("cid", $cid);
+ return $category->promote ? $category->promote : 0;
+}
+
+// return default submission status of category $cid:
+function category_submission($cid) {
+ $category = category_get_object("cid", $cid);
+ return $category->submission ? $category->submission : 0;
}
// return linked string with name of category $cid: