comment_node_type

Definition

comment_node_type($op, $info)
modules/comment/comment.module, line 249

Description

Implementation of hook_node_type().

Code

<?php
function comment_node_type($op, $info) {
  $settings = array(
    'comment',
    'comment_default_mode',
    'comment_default_order',
    'comment_default_per_page',
    'comment_controls',
    'comment_anonymous',
    'comment_subject_field',
    'comment_preview',
    'comment_form_location',
  );
  switch ($op) {
    case 'delete':
      foreach ($settings as $setting) {
        variable_del($setting .'_'. $info->type);
      }
      break;
  }
}
?>
 
 

All source code and documentation on this site is released under the terms of the GNU General Public License, version 2 and later. Drupal is a registered trademark of Dries Buytaert.