function node_convert_bulk_submit in Node Convert 5
File
- ./
node_convert.module, line 283
Code
function node_convert_bulk_submit($form_id, $form_values) {
if ($form_values['step'] == "choose_fields") {
$info = unserialize($form_values['info']);
if ($info['no_fields'] == false) {
// If there are cck fields that can to be converted
foreach ($form_values as $key => $value) {
if (preg_match("/dest_field_[0-9]+?/", $key) == 1) {
$info['fields']['destination'][] = $value;
}
// Destination fields
}
}
foreach ($info['nodes'] as $nid) {
node_convert_node_convert($nid, $info['dest_type'], $info['fields']['source'], $info['fields']['destination'], $info['no_fields']);
}
drupal_set_message("Nodes converted succesufuly.");
drupal_goto("admin/content/node");
}
}