@', $email); return str::email($email, $text); } /** * Returns the Modified Julian Date, * which is the Julian Date with the first two digits stripped * and with an offset of one day to compensate for the Julian Date * starting at noon instead of at midnight * * @param int $timestamp Timestamp to calculate from, defaults to the current date * @return int */ function modifiedJulianDate(?int $timestamp = null): int { $timestamp = $timestamp ?? time(); return gregoriantojd( date('m', $timestamp), date('d', $timestamp), date('Y', $timestamp) ) - 2400001; } /** * dated Kirbytag * * Usage: (dated: Optional link text) */ kirby()->set('tag', 'dated', [ 'html' => function($tag) { return datedHtml($tag->attr('dated')); } ]);