1 entity_example.module | entity_example_basic_add() |
Provides a wrapper on the edit form to add a new entity.
Related topics
File
- modules/
examples/ entity_example/ entity_example.module, line 393 - Hook implementations for the Entity Example module.
Code
function entity_example_basic_add() {
// Create a basic entity structure to be used and passed to the validation
// and submission functions.
$entity = entity_get_controller('entity_example_basic')->create();
return backdrop_get_form('entity_example_basic_form', $entity);
}