X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fevents.php;h=082cdf55dd7ca5401b2bc9ae4c956c1ec0a365e1;hb=7e06127d74565b1c63ca897437ef084a0a7415e0;hp=1b8a509b7015f9c7b9417734494de8350401886e;hpb=a9bb53b021b97ded78c2656186755e61befa4dd4;p=friendica.git diff --git a/mod/events.php b/mod/events.php index 1b8a509b70..082cdf55dd 100644 --- a/mod/events.php +++ b/mod/events.php @@ -1,6 +1,6 @@ t('Event can not end before it has started.')); if (intval($_REQUEST['preview'])) { - echo DI::l10n()->t('Event can not end before it has started.'); - exit(); + System::httpExit(DI::l10n()->t('Event can not end before it has started.')); } DI::baseUrl()->redirect($onerror_path); } @@ -131,8 +131,7 @@ function events_post(App $a) if (!$summary || ($start === DBA::NULL_DATETIME)) { notice(DI::l10n()->t('Event title and start time are required.')); if (intval($_REQUEST['preview'])) { - echo DI::l10n()->t('Event title and start time are required.'); - exit(); + System::httpExit(DI::l10n()->t('Event title and start time are required.')); } DI::baseUrl()->redirect($onerror_path); } @@ -192,9 +191,7 @@ function events_post(App $a) $datarray['id'] = $event_id; if (intval($_REQUEST['preview'])) { - $html = Event::getHTML($datarray); - echo $html; - exit(); + System::httpExit(Event::getHTML($datarray)); } $event_id = Event::store($datarray); @@ -391,8 +388,7 @@ function events_content(App $a) ]); if (!empty($_GET['id'])) { - echo $o; - exit(); + System::httpExit($o); } return $o;