diff options
Diffstat (limited to 'includes')
-rw-r--r-- | includes/hostname.conf | 5 | ||||
-rw-r--r-- | includes/node.inc | 20 |
2 files changed, 11 insertions, 14 deletions
diff --git a/includes/hostname.conf b/includes/hostname.conf index 6b2373b56..dff4d0732 100644 --- a/includes/hostname.conf +++ b/includes/hostname.conf @@ -53,7 +53,8 @@ $themes = array("UnConeD" => array( # Languages / translation / internationalization: # The first language listed in this associative array will automatically become the default language. You can add a language but make sure your SQL table, called locales is updated appropriately. # Translation support - as provided by the default locale module add significant overhead to your site in exchange for excessive maintenance capabilities. If your site does not require translation support, disable it by commenting out the $language variable below. -#$languages = array("en" => "English"); +#$language = array(); // = language support disabled +$languages = array("en" => "English"); # # Submission moderation votes: @@ -76,6 +77,6 @@ $submission_rate = array("comment" => "60", // 60 seconds = 1 minute # Submission size: # The maximum length (i.e. the maximum number of characters) a story, a diary entry, or a comment is allowed to be. # -$submission_size = 12000; // 12.000 characters is appr. 300 lines +$submission_size = 12000; // 12.000 characters is appr. 300 lines ?> diff --git a/includes/node.inc b/includes/node.inc index b682b4e4c..35ba97c71 100644 --- a/includes/node.inc +++ b/includes/node.inc @@ -17,19 +17,15 @@ function node_get_array($field, $value) { return db_fetch_array(_node_get($field, $value)); } -function node_del_object($field, $value) { +function node_del($field, $value) { + global $status; if ($node = node_get_object($field, $value)) { - db_query("DELETE FROM nodes WHERE nid = '$node->nid'"); - db_query("DELETE FROM $node->type WHERE node = '$node->nid'"); - return $node; - } -} - -function node_del_array($field, $value) { - if ($node = node_get_array($field, $value)) { - db_query("DELETE FROM nodes WHERE nid = '$node[nid]'"); - db_query("DELETE FROM $node[type] WHERE node = '$node[nid]'"); - return $node; + if ($node->status == $status[dumped]) { + db_query("DELETE FROM nodes WHERE nid = '$node->nid'"); + db_query("DELETE FROM $node->type WHERE node = '$node->nid'"); + watchdog("message", "deleted node '$node->title'"); + return $node; + } } } |