diff --git a/bible_field.module b/bible_field.module
index e14dd1f..9e5ca06 100755
--- a/bible_field.module
+++ b/bible_field.module
@@ -166,7 +166,20 @@ function bible_field_field_widget_form(&$form, &$form_state, $field, $instance,
         '#suffix' => '</div>',
       );
 
-      $chapter_array = array('0' => t('Chapter')) + array_combine(range(1, BIBLE_FIELD_DEFAULT_COUNT), range(1, BIBLE_FIELD_DEFAULT_COUNT));
+      $book_id = '';
+      if (isset($form_state['values'][$instance['field_name']][$langcode][$delta]['book_id'])) {
+        $book_id = $form_state['values'][$instance['field_name']][$langcode][$delta]['book_id'];
+      }
+      elseif (!empty($value)) {
+        $book_id = $value['book_id'];
+      }
+
+      $chapter_count = BIBLE_FIELD_DEFAULT_COUNT;
+      if (!empty($book_id)) {
+        $chapter_count = db_query('SELECT available_chapters FROM {bible_field_book} WHERE book_id = :book_id', array(':book_id' => $book_id))->fetchField();
+      }
+
+      $chapter_array = array('0' => t('Chapter')) + array_combine(range(1, $chapter_count), range(1, $chapter_count));
       $verse_array = array('0' => t('Verse')) + array_combine(range(1, BIBLE_FIELD_DEFAULT_COUNT), range(1, BIBLE_FIELD_DEFAULT_COUNT));
 
       // Get the version ID
@@ -222,6 +235,14 @@ function bible_field_field_widget_form(&$form, &$form_state, $field, $instance,
         '#attributes' => array('class' => array('biblefield-book-input', 'biblefield-select')),
         '#weight' => 2,
         '#tree' => TRUE,
+        '#ajax' => array(
+          'wrapper' => $wrapper_id,
+          'callback' => 'bible_field_ajax_limit_chapters',
+          'progress' => array(
+            'type' => 'throbber',
+            'message' => '',
+          ),
+        ),
       );
       $element['from'] = array(
         '#markup' => '<div class="form-item">&nbsp;from&nbsp;</div>',
@@ -931,3 +952,16 @@ function bible_field_get_bible_gateway_url($version, $book, $chapters) {
   }
   return 'http://www.biblegateway.com/bible?version=' . $version . '&passage=' . $book . (!empty($chapters) ? '+' . $chapters : '');
 }
+
+/**
+ * FAPI #ajax callback for the book_id select.  This will limit the chapter
+ * list according to the new selection.
+ */
+function bible_field_ajax_limit_chapters($form, $form_state) {
+  $parents = $form_state['triggering_element']['#parents'];
+  $ret = $form[$parents[0]][$parents[1]][$parents[2]];
+  if (isset($ret['_weight'])) {
+    unset($ret['_weight']);
+  }
+  return $ret;
+}
