Created
November 1, 2012 16:10
-
-
Save rafinskipg/3994659 to your computer and use it in GitHub Desktop.
Node types selection for migration modules forms
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$types = node_type_get_types(); | |
$option_types = array(); | |
foreach($types as $type){ | |
$option_types[$type->type] = $type->name; | |
} | |
$form['migration_type'] = array( | |
'#type' => 'select', | |
'#options' => $option_types, | |
'#title' => t('Select the contet type to be created?'), | |
'#default_value' => variable_get('migration_type', ''), | |
'#required' => TRUE, | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment