Index: modules/amazontools/amazon.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/amazontools/amazon.module,v
retrieving revision 1.23
diff -u -r1.23 amazon.module
--- modules/amazontools/amazon.module	19 Nov 2005 20:47:47 -0000	1.23
+++ modules/amazontools/amazon.module	24 Nov 2005 06:04:21 -0000
@@ -475,6 +475,16 @@
       $output .= '</table>';
       $output .= form_submit('Import') . form_submit('Import and continue');
 
+      $_amazon_search_params['TotalPages'] = $_amazon_operation_request['stats'];
+      $output .= form_hidden('BrowseField', $_search_form_values['BrowseField']);
+      $output .= form_hidden('SearchFor', $_search_form_values['SearchFor']);
+
+      foreach ($_amazon_items as $_amazon_item) {
+        $output .= theme_amazon_importitem($_amazon_item);
+      }
+      $output .= '</table>';
+      $output .= form_submit('Import') . form_submit('Import and continue');
+
       $_amazon_search_params['TotalPages'] = $_amazon_operation_request['stats']['TotalPages'];
       $_amazon_search_params['SearchField'] = $_search_form_values['SearchField'];
       $_amazon_search_params['SearchFor'] = $_search_form_values['SearchFor'];
@@ -564,11 +574,16 @@
 function amazon_block($op = 'list', $delta = 0, $edit = array()) {
   switch ($op) {
     case 'configure': {
-      $output = form_textfield(t('Block title'),
-                               'amazon_blocktitle',
-                               variable_get('amazon_blocktitle', t('We recommend')),
-                               30, 120, t('Enter the title for the Amazon product block'));
-      return $output;
+      $form = array();
+      $form['amazon_blocktitle'] = array(
+        '#type' => 'textfield',
+        '#title' => t('Block title'),
+        '#default_value' => variable_get('amazon_blocktitle', t('We recommend')),
+        '#size' => 30,
+        '#maxlength' => 120,
+        '#description' => t('Enter the title for the Amazon product block'),
+      );
+      return $form;
     }
     case 'save': {
       variable_set('amazon_blocktitle', $edit['amazon_blocktitle']);
@@ -641,25 +656,34 @@
   if (function_exists('taxonomy_node_form')) {
     $output = array_merge($form, taxonomy_node_form($node));
   }
-	 $form['asin'] = array(
-  	'#type' => 'textfield',
-  	'#title' => t('ASIN'),
-  	'#default_value' => $node->asin,
-  	'#size' => 20,
-  	'#maxlength' => 100,
-  	'#description' => t('Enter the ASIN of the item.'),
-  	'#weight' => 10
-	);
-	if ($node->type == 'amazon') {
-		$form['body'] = array(
-			'#type' => 'textarea',
-			'#title' => t('Body'),
-			'#default_value' => $node->body,
-			'#cols' => 60,
-			'#rows' => 20,
-			'#weight' => 10
-		);
-	}
+  if ($node->type == 'amazon') {
+    $form['title'] = array(
+      '#type' => 'textfield',
+      '#title' => t('Title'),
+      '#required' => FALSE,
+      '#default_value' => $node->title
+    );
+
+    $form['body'] = array(
+      '#type' => 'textarea',
+      '#title' => t('Body'),
+      '#default_value' => $node->body,
+      '#rows' => 20,
+      '#required' => TRUE
+    );
+    $form = array_merge($form, filter_form($node->format));
+  }
+
+  $form['asin'] = array(
+    '#type' => 'textfield',
+    '#title' => t('ASIN'),
+    '#default_value' => $node->asin,
+    '#size' => 20,
+    '#maxlength' => 100,
+    '#description' => t('Enter the ASIN of the item.'),
+    '#weight' => -16
+  );
+  
   return $form;
 }
 
@@ -1016,4 +1040,4 @@
     }
   }
 }
-?>
\ No newline at end of file
+
