Thanks for answering, I was watching these days if you can modify the CCK module to store the data for each form in its corresponding table (custom) but there is nothing on the internet and I do not see that method gets data from the form and that line insert the form data. I am now trying to create my module (I have to create a module for each form and that are distinct and input data is stored in different custom tables) and got to add the menu but can not get it when doing Visualize click the menu, that is, for example, the module created is index appears on the menu as to give 'form' appears a blank page as if not what is in formula_form function (). This is my module.form :
Code:
form_menu function () {
$ Items ['form'] = array (
'Title' => 'form',
'Page callback' => 'form',
'Access callback' => TRUE,
'Access arguments' => array ('content type'),
'Type' => MENU_NORMAL_ITEM, // appears in the menu
)
$ Items ['menu_mas'] = array (
'Title' => 'Example form',
'Page callback' => 'drupal_get_form'
'Access callback' => TRUE,
'Access arguments' => array ('content type'),
'Type' => MENU_NORMAL_ITEM, // appears in the menu
)
return $ items;
}
form_page function () {
drupal_get_form return ('index_form');
}
Index_form function () {
$ Form ['form'] = array (
'# Title' => t ('name')
'# Type' => 'textfield',
'# Description' => t ('Please enter your name'),
)
$ Form ['submit'] = array (
'# Type' => 'submit'
'# Value' => t ('Submit')
)
return $ form;
}
Index_form_submit function ($ form_id, $ form_values) {
$ Message = "There have been the ';
drupal_set_message (t ('$ Message'));
}
I do not know because I see the form. I guess in the $ form ['submit'] I have to point to another method that is the one responsible for storing the data in the table for you?
Bookmarks