| 1 |
<?php |
<?php |
| 2 |
// $Id: category.admin.inc,v 1.3 2009/02/07 09:01:16 jaza Exp $ |
// $Id: category.admin.inc,v 1.4 2009/05/31 10:16:11 jaza Exp $ |
| 3 |
|
|
| 4 |
/** |
/** |
| 5 |
* @file |
* @file |
| 114 |
*/ |
*/ |
| 115 |
function theme_category_overview_containers($form) { |
function theme_category_overview_containers($form) { |
| 116 |
$rows = array(); |
$rows = array(); |
| 117 |
|
|
| 118 |
|
$cols = 4; |
| 119 |
|
if (variable_get('category_container_hierarchy', 0) > 0) { |
| 120 |
|
$cols++; |
| 121 |
|
} |
| 122 |
|
|
| 123 |
foreach (element_children($form) as $key) { |
foreach (element_children($form) as $key) { |
| 124 |
if (isset($form[$key]['name'])) { |
if (isset($form[$key]['name'])) { |
| 125 |
$container = &$form[$key]; |
$container = &$form[$key]; |
| 127 |
$row = array(); |
$row = array(); |
| 128 |
$row[] = drupal_render($container['name']); |
$row[] = drupal_render($container['name']); |
| 129 |
$row[] = drupal_render($container['types']); |
$row[] = drupal_render($container['types']); |
|
$cols = 4; |
|
| 130 |
if (variable_get('category_container_hierarchy', 0) > 0) { |
if (variable_get('category_container_hierarchy', 0) > 0) { |
| 131 |
$row[] = drupal_render($container['parents']); |
$row[] = drupal_render($container['parents']); |
|
$cols++; |
|
| 132 |
} |
} |
| 133 |
if (isset($form['submit'])) { |
if (isset($form['submit'])) { |
| 134 |
$container['weight']['#attributes']['class'] = 'container-weight'; |
$container['weight']['#attributes']['class'] = 'container-weight'; |
| 746 |
function category_wrapper_admin_page() { |
function category_wrapper_admin_page() { |
| 747 |
$book_status = category_get_wrapper_status('book'); |
$book_status = category_get_wrapper_status('book'); |
| 748 |
$taxonomy_status = category_get_wrapper_status('taxonomy'); |
$taxonomy_status = category_get_wrapper_status('taxonomy'); |
|
$menu_status = category_get_wrapper_status('menu'); |
|
| 749 |
$form['book_wrapper'] = array( |
$form['book_wrapper'] = array( |
| 750 |
'#type' => 'item', |
'#type' => 'item', |
| 751 |
'#title' => t('Book wrapper status'), |
'#title' => t('Book wrapper status'), |
| 756 |
'#title' => t('Taxonomy wrapper status'), |
'#title' => t('Taxonomy wrapper status'), |
| 757 |
'#value' => theme('category_wrapper_status', 'taxonomy', $taxonomy_status), |
'#value' => theme('category_wrapper_status', 'taxonomy', $taxonomy_status), |
| 758 |
); |
); |
|
$form['menu_wrapper'] = array( |
|
|
'#type' => 'item', |
|
|
'#title' => t('Menu wrapper status'), |
|
|
'#value' => theme('category_wrapper_status', 'menu', $menu_status), |
|
|
); |
|
| 759 |
|
|
| 760 |
return $form; |
return $form; |
| 761 |
} |
} |