diff --git a/CRM/Event/Form/Registration/ThankYou.php b/CRM/Event/Form/Registration/ThankYou.php index 3d1a8b16591b..694933d150ad 100644 --- a/CRM/Event/Form/Registration/ThankYou.php +++ b/CRM/Event/Form/Registration/ThankYou.php @@ -158,27 +158,30 @@ public function buildQuickForm() { $params['entity_table'] = 'civicrm_event'; $data = []; - $friendURL = NULL; + $extensionText = []; if (function_exists('tellafriend_civicrm_config')) { + // @todo - move this to tellafriend extension CRM_Friend_BAO_Friend::retrieve($params, $data); if (!empty($data['is_active'])) { $friendText = $data['title']; - $this->assign('friendText', $friendText); if ($this->_action & CRM_Core_Action::PREVIEW) { $friendURL = CRM_Utils_System::url('civicrm/friend', - "eid={$this->_eventId}&reset=1&action=preview&pcomponent=event" + "eid={$this->getEventID()}&reset=1&action=preview&pcomponent=event" ); } else { $friendURL = CRM_Utils_System::url('civicrm/friend', - "eid={$this->_eventId}&reset=1&pcomponent=event" + "eid={$this->getEventID()}&reset=1&pcomponent=event" ); } + $extensionText[] = '"