function _hosting_wizard_cleanse_node_form in Hosting 5
Take a node form and get rid of all the crud that we don't need on a wizard form, in a non destructive manner.
3 calls to _hosting_wizard_cleanse_node_form()
- hosting_wizard_provision_db in ./
hosting.wizard.inc - Database configuration form
- hosting_wizard_provision_paths in ./
hosting.wizard.inc - Configures web_server_node_form paths.
- hosting_wizard_provision_web in ./
hosting.wizard.inc - Configures web_server_node_form minus almost all the forms.
File
- ./
hosting.wizard.inc, line 511
Code
function _hosting_wizard_cleanse_node_form(&$form) {
$form['log']['#type'] = 'value';
$form['author']['name']['#type'] = 'value';
$form['author']['date']['#type'] = 'value';
$form['options']['status']['#type'] = 'value';
$form['options']['promote']['#type'] = 'value';
$form['options']['sticky']['#type'] = 'value';
$form['options']['revision']['#type'] = 'value';
$form['options']['#type'] = 'markup';
$form['author']['#type'] = 'markup';
// get rid of buttons (we replace submit anyway)
unset($form['submit']);
unset($form['preview']);
unset($form['delete']);
}