Skip to content

Instantly share code, notes, and snippets.

View MHz-Git's full-sized avatar

Simon Ince MHz-Git

View GitHub Profile
$form['add_date'] = array(
'#type' => 'button',
'#value' => t('Preview'),
'#weight' => 19,
'#submit' => array('hook_node_update'),
);
hook_node_update($node) {
db_update('mytable')
->fields(array('extra' => $node->extra))