1 contextual_links_example.module contextual_links_example_object_edit_form($form, &$form_state, $object)

Form callback; display the form for editing our module's content.

See also

contextual_links_example_object_edit_form_submit()

Related topics

File

modules/examples/contextual_links_example/contextual_links_example.module, line 324
Hooks implementations for the Contextual Links Example module.

Code

function contextual_links_example_object_edit_form($form, &$form_state, $object) {
  $form['text'] = array(
    '#markup' => t('This is the page that would allow you to edit object @id.', array('@id' => $object->id)),
    '#prefix' => '<p>',
    '#suffix' => '</p>',
  );
  $form['object_id'] = array(
    '#type' => 'value',
    '#value' => $object->id,
  );

  $form['actions'] = array('#type' => 'actions');
  $form['actions']['submit'] = array(
    '#type' => 'submit',
    '#value' => t('Submit'),
  );

  return $form;
}