From ae85abb9833e0600afa0595a912be8065f8bccab Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Fri, 5 Nov 2010 19:47:20 +0000 Subject: - Patch #955610 by casey: impossible to have multiple node forms on one page due to fixed IDs. --- modules/path/path.js | 4 ++-- modules/path/path.module | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) (limited to 'modules/path') diff --git a/modules/path/path.js b/modules/path/path.js index e065d94b5..881724df4 100644 --- a/modules/path/path.js +++ b/modules/path/path.js @@ -4,8 +4,8 @@ Drupal.behaviors.pathFieldsetSummaries = { attach: function (context) { - $('fieldset#edit-path', context).drupalSetSummary(function (context) { - var path = $('#edit-path-alias').val(); + $('fieldset.path-form', context).drupalSetSummary(function (context) { + var path = $('.form-item-path-alias input').val(); return path ? Drupal.t('Alias: @alias', { '@alias': path }) : diff --git a/modules/path/path.module b/modules/path/path.module index 0e5874357..67ecaa4ea 100644 --- a/modules/path/path.module +++ b/modules/path/path.module @@ -119,6 +119,9 @@ function path_form_node_form_alter(&$form, $form_state) { '#collapsible' => TRUE, '#collapsed' => empty($path['alias']), '#group' => 'additional_settings', + '#attributes' => array( + 'class' => array('path-form'), + ), '#attached' => array( 'js' => array(drupal_get_path('module', 'path') . '/path.js'), ), -- cgit v1.2.3