function entity_translation_add_page in Entity Translation 7
Page callback.
1 string reference to 'entity_translation_add_page'
- entity_translation_menu_alter in ./
entity_translation.module - Implements hook_menu_alter().
File
- ./
entity_translation.module, line 697
Code
function entity_translation_add_page() {
$args = func_get_args();
$entity_type = array_shift($args);
$entity = array_shift($args);
$source = array_shift($args);
$langcode = array_shift($args);
$edit_form_item = array_shift($args);
$handler = entity_translation_get_handler($entity_type, $entity);
$handler
->initPathScheme();
$handler
->setActiveLanguage($langcode);
$handler
->setSourceLanguage($source);
// Display the entity edit form.
return _entity_translation_callback($edit_form_item['page callback'], $args, $edit_form_item);
}