function flag_add_page in Flag 6.2
Same name and namespace in other branches
- 5 includes/flag.admin.inc \flag_add_page()
- 6 includes/flag.admin.inc \flag_add_page()
- 7.3 includes/flag.admin.inc \flag_add_page()
- 7.2 includes/flag.admin.inc \flag_add_page()
Menu callback for adding a new flag.
1 string reference to 'flag_add_page'
- flag_menu in ./
flag.module - Implementation of hook_menu().
File
- includes/
flag.admin.inc, line 198 - Contains administrative pages for creating, editing, and deleting flags.
Code
function flag_add_page($type = NULL, $name = NULL) {
drupal_set_title(t('Add new flag'));
if (isset($type) && isset($name)) {
$flag = flag_flag::factory_by_content_type($type);
$flag->name = $name;
return drupal_get_form('flag_form', $flag);
}
else {
return drupal_get_form('flag_add_form');
}
}