summaryrefslogtreecommitdiff
path: root/modules/block.module
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2005-12-05 09:11:33 +0000
committerDries Buytaert <dries@buytaert.net>2005-12-05 09:11:33 +0000
commit28fdb3975e2bc53061277f4fdb1147dc8d3ba128 (patch)
tree06c355049d6e98b30417addd2a0942962e4f18cc /modules/block.module
parent3e36be3b24423566e6d9de2c1c8cbea5ca68b295 (diff)
downloadbrdo-28fdb3975e2bc53061277f4fdb1147dc8d3ba128.tar.gz
brdo-28fdb3975e2bc53061277f4fdb1147dc8d3ba128.tar.bz2
- Patch #39778 by chx: obliterate nodeapi op form in favor of the forms API's way of doing things. Tested with help from webchick.
Diffstat (limited to 'modules/block.module')
-rw-r--r--modules/block.module28
1 files changed, 25 insertions, 3 deletions
diff --git a/modules/block.module b/modules/block.module
index c07b56851..d15f3ed4c 100644
--- a/modules/block.module
+++ b/modules/block.module
@@ -445,10 +445,32 @@ function block_box_delete_confirm_submit($form_id, $form_values) {
function block_box_form($edit = array()) {
- $form['title'] = array('#type' => 'textfield', '#title' => t('Block title'), '#default_value' => $edit['title'], '#maxlength' => 64, '#description' => t('The title of the block as shown to the user.'));
+ $form['title'] = array(
+ '#type' => 'textfield',
+ '#title' => t('Block title'),
+ '#default_value' => $edit['title'],
+ '#maxlength' => 64,
+ '#description' => t('The title of the block as shown to the user.'),
+ '#weight' => -18,
+ );
+ $form['body'] = array(
+ '#type' => 'textarea',
+ '#title' => t('Block body'),
+ '#default_value' => $edit['body'],
+ '#rows' => 15,
+ '#description' => t('The content of the block as shown to the user.'),
+ '#weight' => -17,
+ );
$form['format'] = filter_form($edit['format']);
- $form['body'] = array('#type' => 'textarea', '#title' => t('Block body'), '#default_value' => $edit['body'], '#rows' => 15, '#description' => t('The content of the block as shown to the user.'));
- $form['info'] = array('#type' => 'textfield', '#title' => t('Block description'), '#default_value' => $edit['info'], '#maxlength' => 64, '#description' => t('A brief description of your block. Used on the <a href="%overview">block overview page</a>.', array('%overview' => url('admin/block'))), '#required' => TRUE);
+ $form['info'] = array(
+ '#type' => 'textfield',
+ '#title' => t('Block description'),
+ '#default_value' => $edit['info'],
+ '#maxlength' => 64,
+ '#description' => t('A brief description of your block. Used on the <a href="%overview">block overview page</a>.', array('%overview' => url('admin/block'))),
+ '#required' => TRUE,
+ '#weight' => -15,
+ );
return $form;
}