2009-02-19

Content page customization in Drupal

If you want to customize Content page (admin/content/node) in Drupal (on screen below) you can insert form altering hook:




/**
* Implementation of hook_form_alter().
*/
function custom_form_alter(&$form, $form_state, $form_id) {
if($form_id == 'node_admin_content') { // form overview name
// available fields:
// $form['admin']['title'][nid]
// $form['admin']['name'][nid]
// $form['admin']['username'][nid]
// $form['admin']['status'][nid]
// $form['admin']['language'][nid]

// or in simplest way
echo "
";
print_r($form['admin']);
echo "
";
}
}

No comments: