You are here

public function InviteLinkBlockForm::ajaxReplaceInviteContainer in Invite 8

Function to Ajax Replace.

File

modules/invite_link/src/Form/InviteLinkBlockForm.php, line 52

Class

InviteLinkBlockForm
Class InviteLinkBlockForm.

Namespace

Drupal\invite_link\Form

Code

public function ajaxReplaceInviteContainer($form, FormStateInterface $form_state) {
  $form['invite_container']['#markup'] = '<div id="invite">  <a href="/invite/accept/' . $form_state
    ->getTemporaryValue('invite')
    ->getRegCode() . '">Invite Link</a></div>';
  return $form['invite_container'];
}