Ignore:
Timestamp:
Jan 14, 2012, 11:29:10 PM (12 years ago)
Author:
mistic100
Message:

feature:2549 Allow to disable comments for everybody

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/admin/user_list.php

    r12886 r12887  
    416416  $dbfields = array('primary' => array('user_id'), 'update' => array());
    417417
    418   $formfields =
    419     array('nb_image_page', 'theme', 'language',
    420           'recent_period', 'expand', 'show_nb_comments',
    421           'show_nb_hits', 'status', 'enabled_high',
    422           'level');
    423 
    424   $true_false_fields = array('expand', 'show_nb_comments',
    425                        'show_nb_hits', 'enabled_high');
     418  $formfields = array(
     419          'nb_image_page', 'theme', 'language',
     420          'recent_period', 'expand', 'show_nb_hits',
     421          'status', 'enabled_high', 'level'
     422          );
     423 
     424  $true_false_fields = array('expand', 'show_nb_hits', 'enabled_high');
     425 
     426  if ($conf['activate_comments'])
     427  {
     428    array_push($formfields, 'show_nb_comments');
     429    array_push($true_false_fields, 'show_nb_comments');
     430  }
    426431
    427432  foreach ($formfields as $formfield)
     
    556561    'F_ADD_ACTION' => $base_url,
    557562    'F_USERNAME' => @htmlentities($_GET['username'], ENT_COMPAT, 'UTF-8'),
    558     'F_FILTER_ACTION' => get_root_url().'admin.php'
     563    'F_FILTER_ACTION' => get_root_url().'admin.php',
     564   
     565    'ACTIVATE_COMMENTS' => $conf['activate_comments'],
    559566    ));
    560567
Note: See TracChangeset for help on using the changeset viewer.