Hello,
I have a 'press release' content type the client likes that I'm trying to export from one website and import into another. For some reason I'm getting the following error twice when attempting to import:

"An illegal choice has been detected. Please contact the site administrator."

*cough... I am the site administrator.

How do I figure out what illegal choice has been made, and how would I correct this issue? Both websites have the same modules installed. I'm guessing there is something going on with dates, check boxes, or both based on what I searched so far via google. I just can't seem to find the right 'how to fix it' page.

The export is below. I much appreciate the assistance in advance! :)

$content['type']  = array (
  'name' => 'Press Release',
  'type' => 'press_release',
  'description' => 'News briefs and press releases are basically the same structurally, but how they are used once published are different. They are never both a brief and a release at the same time. They are also shown in different sub-sections of the website.',
  'title_label' => 'Title',
  'body_label' => 'Body',
  'min_word_count' => '0',
  'help' => '',
  'node_options' =>
  array (
    'status' => true,
    'promote' => false,
    'sticky' => false,
    'revision' => false,
  ),
  'language_content_type' => '0',
  'upload' => '1',
  'parentmenu' => 'primary-links:731',
  'parentmenuen' => 'primary-links:731',
  'automenu_hide' => 1,
  'nodewords' => 1,
  'old_type' => 'press_release',
  'orig_type' => '',
  'module' => 'node',
  'custom' => '1',
  'modified' => '1',
  'locked' => '0',
  'xmlsitemap_node_type_priority' => 0.5,
  'comment' => '0',
  'comment_default_mode' => '4',
  'comment_default_order' => '1',
  'comment_default_per_page' => '50',
  'comment_controls' => '3',
  'comment_anonymous' => 0,
  'comment_subject_field' => '1',
  'comment_preview' => '1',
  'comment_form_location' => '0',
);
$content['fields']  = array (
  0 =>
  array (
    'label' => 'Show in Home Latest News Box',
    'field_name' => 'field_show_in_home_latest',
    'type' => 'text',
    'widget_type' => 'optionwidgets_buttons',
    'change' => 'Change basic information',
    'weight' => '-1',
    'description' => 'Check this if you want this post to show on the home page "Latest News" box while it is hot and fresh. It will eventually fall off the home page after other newer posts are checked for the home page. No matter what, this post will ALWAYS be visible in its appropriate section of the site.',
    'default_value' =>
    array (
      0 =>
      array (
        'value' => 'Show on home page',
      ),
    ),
    'default_value_php' => '',
    'default_value_widget' => NULL,
    'group' => false,
    'required' => 1,
    'multiple' => '0',
    'text_processing' => '0',
    'max_length' => '',
    'allowed_values' => 'Show on home page
Don\'t show on home page',
    'allowed_values_php' => '',
    'op' => 'Save field settings',
    'module' => 'text',
    'widget_module' => 'optionwidgets',
    'columns' =>
    array (
      'value' =>
      array (
        'type' => 'text',
        'size' => 'big',
        'not null' => false,
        'sortable' => true,
        'views' => true,
      ),
    ),
    'display_settings' =>
    array (
      'weight' => '-1',
      'parent' => '',
      'label' =>
      array (
        'format' => 'hidden',
      ),
      'teaser' =>
      array (
        'format' => 'hidden',
        'exclude' => 1,
      ),
      'full' =>
      array (
        'format' => 'hidden',
        'exclude' => 1,
      ),
      4 =>
      array (
        'format' => 'default',
        'exclude' => 0,
      ),
      'token' =>
      array (
        'format' => 'default',
        'exclude' => 0,
      ),
    ),
  ),
  1 =>
  array (
    'label' => 'Publish Date',
    'field_name' => 'field_defined_publish_date',
    'type' => 'datestamp',
    'widget_type' => 'date_popup',
    'change' => 'Change basic information',
    'weight' => 0,
    'default_value' => 'now',
    'default_value2' => 'now',
    'default_value_code' => '',
    'default_value_code2' => '',
    'input_format' => 'j F Y - g:ia',
    'input_format_custom' => '',
    'year_range' => '-1:+1',
    'increment' => '1',
    'advanced' =>
    array (
      'label_position' => 'above',
      'text_parts' =>
      array (
        'year' => 0,
        'month' => 0,
        'day' => 0,
        'hour' => 0,
        'minute' => 0,
        'second' => 0,
      ),
    ),
    'label_position' => 'above',
    'text_parts' =>
    array (
    ),
    'description' => 'What date do you want to be listed as the publish date? This will effect how things are sorted and dated. If posting to the future, be sure to uncheck the published option in the publish options below (may be hidden in a collapsed menu), then check it when it needs to go live.',
    'group' => false,
    'required' => 1,
    'multiple' => '0',
    'repeat' => 0,
    'todate' => '',
    'granularity' =>
    array (
      'year' => 'year',
      'month' => 'month',
      'day' => 'day',
      'hour' => 'hour',
      'minute' => 'minute',
    ),
    'default_format' => 'long',
    'tz_handling' => 'site',
    'timezone_db' => 'UTC',
    'op' => 'Save field settings',
    'module' => 'date',
    'widget_module' => 'date',
    'columns' =>
    array (
      'value' =>
      array (
        'type' => 'int',
        'not null' => false,
        'sortable' => true,
        'views' => true,
      ),
    ),
    'display_settings' =>
    array (
      'weight' => 0,
      'parent' => '',
      'label' =>
      array (
        'format' => 'hidden',
      ),
      'teaser' =>
      array (
        'format' => 'short',
        'exclude' => 0,
      ),
      'full' =>
      array (
        'format' => 'hidden',
        'exclude' => 0,
      ),
      4 =>
      array (
        'format' => 'default',
        'exclude' => 0,
      ),
      'token' =>
      array (
        'format' => 'default',
        'exclude' => 0,
      ),
    ),
  ),
  2 =>
  array (
    'label' => 'Contact Information',
    'field_name' => 'field_sf_contact_info',
    'type' => 'text',
    'widget_type' => 'text_textarea',
    'change' => 'Change basic information',
    'weight' => '3',
    'rows' => '5',
    'size' => 60,
    'description' => '',
    'default_value' =>
    array (
      0 =>
      array (
        'value' => '<p><strong>Contact:</strong><br /> contact info here...</p>',
        'format' => '3',
        '_error_element' => 'default_value_widget][field_sf_contact_info][0][value',
      ),
    ),
    'default_value_php' => '',
    'default_value_widget' =>
    array (
      'field_sf_contact_info' =>
      array (
        0 =>
        array (
          'value' => '<p><strong>Contact:</strong><br /> contact info here...</p>',
          'format' => '3',
          '_error_element' => 'default_value_widget][field_sf_contact_info][0][value',
        ),
      ),
    ),
    'group' => false,
    'required' => 0,
    'multiple' => '0',
    'text_processing' => '1',
    'max_length' => '',
    'allowed_values' => '',
    'allowed_values_php' => '',
    'op' => 'Save field settings',
    'module' => 'text',
    'widget_module' => 'text',
    'columns' =>
    array (
      'value' =>
      array (
        'type' => 'text',
        'size' => 'big',
        'not null' => false,
        'sortable' => true,
        'views' => true,
      ),
      'format' =>
      array (
        'type' => 'int',
        'unsigned' => true,
        'not null' => false,
        'views' => false,
      ),
    ),
    'display_settings' =>
    array (
      'weight' => '3',
      'parent' => '',
      'label' =>
      array (
        'format' => 'hidden',
      ),
      'teaser' =>
      array (
        'format' => 'hidden',
        'exclude' => 1,
      ),
      'full' =>
      array (
        'format' => 'default',
        'exclude' => 0,
      ),
      4 =>
      array (
        'format' => 'default',
        'exclude' => 0,
      ),
      'token' =>
      array (
        'format' => 'default',
        'exclude' => 0,
      ),
    ),
  ),
);
$content['extra']  = array (
  'title' => '-2',
  'body_field' => '1',
  'menu' => '-3',
  'attachments' => '2',
);

Comments

I got this figured out at experts-exchange.com. Basically, the automenu module was not configured the same way and had different menus from where I was importing from. I was able to see that specifically in the recent log entries after the errors showed up when trying to import. 3 lines related ing automenu were removed from the export, and all is well when importing. :)

Worlds to explore. Worlds to create.
Blog: http://www.christopherstevens.cc/blog
Twitter: http://www.twitter.com/owntheweb

I had a similar situation and fixed it by:

1) Updating my versions of modules "Unique fields" and "Primary terms"
2) I disabled these modules during my import

...and the content type import worked fine. Note that updating the mods might have had nothing to do with the fix - I just did this first. The import didn't work till I disabled both modules.

Looking at "Reports > Recent Log Entries..." as outlined above led me to this fix, telling me which modules were causing the issue.

This page shed some additional light:
http://drupal.org/node/570976

ALSO NOTE: Ubercart existed on my prior site, the one I was exporting from; it did not exist on the "new" site (at least had not been loaded) - so my import/export was hampered until I removed all trace of Ubercart in the export text file. This is important to note because there was no mention of this in the error reports. It told me it imported the content type -but also said there was an error and there was no listing of said import. The error turned out to be caused by Ubercart references.

Same problem here. I just removed these lines from my exported array and it worked importing it.
'menu' =>
array (
1 => 1,
'devel' => false,
'navigation' => false,
'primary-links' => false,
'secondary-links' => false,
),

thanks

Eric

In my case, I had only "Unique Field" installed, not "Primary terms." Still not fixed as of now: #570976: CCK import fails

After the import, the "Unique Field" settings have to be re-applied manually.

Thanks for posting this! and thank you Google for helping me find it. I was bashing my head into the wall trying to figure out what was going on. And yes looking up recent logs helped find the culprit. Mine was unique fields as well. I didn't have to disable the module, but I did simply disabled the unique field check on whatever content type I was copying and this allowed me to import successfully.

Thanks!!!!!