开发者

changing drupal 6 form and submit for exsiting content type

hey i got a contnet type that i made and i want to twweak it some , when i do form alter its all good but once i do submit its ignore my changes that i added a field for example, how can i do that changes and tel开发者_JS百科l him to insert also that field? do i need to put all the fields again in hook_submit?


$function YOURMODULE_form_alter(&$form, &$form_state) {
  //...
  $form['#submit'][] = 'YOURMODULE_submitfunction';
  //...
}

function YOURMODULE_submitfunction($form, &$form_state) {
  // Save your own changes here to DB or something other
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜