summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorGábor Hojtsy <gabor@hojtsy.hu>2007-08-18 11:36:40 +0000
committerGábor Hojtsy <gabor@hojtsy.hu>2007-08-18 11:36:40 +0000
commit9361518ce842e394425a6d2b6a47170ef3134238 (patch)
tree2456198fc91b20bc1e49c8069eeb93c8458dd1d8 /modules
parent0a6cf705b840f9199438b3669bd11217f17fe6e8 (diff)
downloadbrdo-9361518ce842e394425a6d2b6a47170ef3134238.tar.gz
brdo-9361518ce842e394425a6d2b6a47170ef3134238.tar.bz2
#166913 by pwolanin and webernet: fix book outline removal confirm form parameters and improve user documentation
Diffstat (limited to 'modules')
-rw-r--r--modules/book/book.module10
1 files changed, 9 insertions, 1 deletions
diff --git a/modules/book/book.module b/modules/book/book.module
index 70e4cd727..1e4eb7ef0 100644
--- a/modules/book/book.module
+++ b/modules/book/book.module
@@ -539,8 +539,16 @@ function book_remove_button_submit($form, &$form_state) {
*/
function book_remove_form(&$form_state, $node) {
$form['#node'] = $node;
+ $title = array('%title' => $node->title);
- return confirm_form($form, t('Are you sure you want to remove %title from the book hierarchy?', array('%title' => $node->title)), 'node/'. $node->nid, array('yes' => t('Remove')));
+ if ($node->book['has_children']) {
+ $description = t('%title has associated child pages, which will be relocated automatically to maintain their connection to the book. To recreate the hierarchy (as it was before removing this page), %title may be added again using the Outline tab, and each of its former child pages will need to be relocated manually.', $title);
+ }
+ else {
+ $description = t('%title may be added to hierarchy again using the Outline tab.', $title);
+ }
+
+ return confirm_form($form, t('Are you sure you want to remove %title from the book hierarchy?', $title), 'node/'. $node->nid, $description, t('Remove'));
}
/**