176a177,221
> 
> $element['exceptions'] = array(
>     '#type' => 'fieldset',
>     '#collapsible' => TRUE,
>     '#collapsed' => empty($exceptions) ? TRUE : FALSE,
>     '#title' => t('Except'),
>     '#description' => t('Dates to omit from the list of repeating dates.'),
>     '#prefix' => '<div id="date-repeat-exceptions" class="date-repeat">',
>     '#suffix' => '</div>',
>     );
>   $max = !empty($exceptions) ? sizeof($exceptions) : 0;
>   for ($i = 0; $i <= $max; $i++) {
>     $EXCEPT = '';
>     if (!empty($exceptions[$i]['datetime'])) {
>       $EXCEPT = $exceptions[$i]['datetime'];
>     }
>     $element['exceptions']['EXDATE'][$i] = array(
>       '#tree' => TRUE,
>       'datetime' => array(
>         '#type' => $element['#date_repeat_widget'],
>         '#default_value' => $EXCEPT,
>         '#date_timezone' => !empty($element['#date_timezone']) ? $element['#date_timezone'] : date_default_timezone_name(),
>         '#date_format' => !empty($element['#date_format']) ? date_limit_format($element['#date_format'], array('year', 'month', 'day')) : 'Y-m-d',
>         '#date_text_parts'  => !empty($element['#date_text_parts']) ? $element['#date_text_parts'] : array(),
>         '#date_year_range'  => !empty($element['#date_year_range']) ? $element['#date_year_range'] : '-3:+3',
>         '#date_label_position' => !empty($element['#date_label_position']) ? $element['#date_label_position'] : 'within',
>         ),
>       'tz' => array('#type' => 'hidden', '#value' => $element['#date_timezone']),
>       'all_day' => array('#type' => 'hidden', '#value' => 1),
>       'granularity' => array('#type' => 'hidden', '#value' => serialize(array('year', 'month', 'day'))),
>       );
>   }
> $field_name = $element['#parents'][0];
>   $element['exceptions']['exceptions_addmore'] = array(
>     '#type' => 'button',
>     '#value' => t('Add more exceptions'),
>     '#ahah' => array(
>       'event' => 'click',
>       'path' => 'date_repeat_get_exception_form_ajax/exceptions/' . $field_name,
>       'wrapper' => 'date-repeat-exceptions',
>       'method' => 'replace',
>       'effect' => 'fade'
>     )
>   );
> 
248c293
<   }  
---
>   }
