How to modify a form field?
When you are using this syntax:

$form['submitted']['dia'] = array(


you create a whole new array, with only the values you provided. Old array that was there is simply discarded. If you only want to add or modify 'options', 'default_value', and 'ajax', you need to access them directly:

$form['submitted']['dia']['options'] = $options_first;
$form['submitted']['dia']['default_value'] = $selected;
$form['submitted']['dia']['ajax'] = array(
  'callback' =&gt; 'ajax_example_dependent_dropdown_callback',
  'wrapper' =&gt; 'dropdown-second-replace',
);