From 922a46d28159737a61602876b961147f46428267 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Thu, 15 Dec 2005 16:24:40 +0000 Subject: - Patch #34920 by Morbus/webchick/tangent: fixed order of form fields. --- modules/node/node.module | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'modules/node/node.module') diff --git a/modules/node/node.module b/modules/node/node.module index 37317c522..1eb05e96c 100644 --- a/modules/node/node.module +++ b/modules/node/node.module @@ -1614,10 +1614,10 @@ function node_form($node) { // Get the node-specific bits. $form = array_merge($form, node_invoke($node, 'form')); if (!isset($form['title']['#weight'])) { - $form['title']['#weight'] = -18; + $form['title']['#weight'] = -5; } if (!isset($form['body']['#weight'])) { - $form['body']['#weight'] = -17; + $form['body']['#weight'] = 0; } // If this is a new node, fill in the default values. @@ -1640,13 +1640,13 @@ function node_form($node) { if (user_access('administer nodes')) { // Node author information - $form['author'] = array('#type' => 'fieldset', '#title' => t('Authoring information'), '#collapsible' => TRUE, '#collapsed' => TRUE, '#weight' => -5); + $form['author'] = array('#type' => 'fieldset', '#title' => t('Authoring information'), '#collapsible' => TRUE, '#collapsed' => TRUE, '#weight' => 20); $form['author']['name'] = array('#type' => 'textfield', '#title' => t('Authored by'), '#maxlength' => 60, '#autocomplete_path' => 'user/autocomplete', '#required' => TRUE, '#default_value' => $node->name, '#weight' => -1); $form['author']['date'] = array('#type' => 'textfield', '#title' => t('Authored on'), '#maxlength' => 25, '#required' => TRUE, '#default_value' => $node->date); // Node options for administrators - $form['options'] = array('#type' => 'fieldset', '#title' => t('Publishing options'), '#collapsible' => TRUE, '#collapsed' => TRUE, '#weight' => -5); + $form['options'] = array('#type' => 'fieldset', '#title' => t('Publishing options'), '#collapsible' => TRUE, '#collapsed' => TRUE, '#weight' => 25); $form['options']['status'] = array('#type' => 'checkbox', '#title' => t('Published'), '#default_value' => $node->status); $form['options']['moderate'] = array('#type' => 'checkbox', '#title' => t('In moderation queue'), '#default_value' => $node->moderate); $form['options']['promote'] = array('#type' => 'checkbox', '#title' => t('Promoted to front page'), '#default_value' => $node->promote); @@ -1663,11 +1663,10 @@ function node_form($node) { } // Add the buttons. - $form['preview'] = array('#type' => 'button', '#value' => t('Preview'), '#weight' => 19); - - $form['submit'] = array('#type' => 'submit', '#value' => t('Submit'), '#weight' => 20); + $form['preview'] = array('#type' => 'button', '#value' => t('Preview'), '#weight' => 40); + $form['submit'] = array('#type' => 'submit', '#value' => t('Submit'), '#weight' => 45); if ($node->nid && node_access('delete', $node)) { - $form['delete'] = array('#type' => 'button', '#value' => t('Delete'), '#weight' => 21); + $form['delete'] = array('#type' => 'button', '#value' => t('Delete'), '#weight' => 50); } if ($op == t('Preview')) { -- cgit v1.2.3