X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fevents.php;h=e601ce8e4e82bf9332184aebca452ff23b7972da;hb=389b7de451eb8e684b48e2c96598f1d12c1465d9;hp=e9e1af05d8044bd26b86ddfd99a50f736fddbdca;hpb=50b3e49b5d226943219ab1df40146643a85d5548;p=friendica.git diff --git a/mod/events.php b/mod/events.php index e9e1af05d8..e601ce8e4e 100644 --- a/mod/events.php +++ b/mod/events.php @@ -179,14 +179,68 @@ function events_content(&$a) { ); } + if ($a->theme_events_in_profile) + nav_set_selected('home'); + else + nav_set_selected('events'); $editselect = 'none'; if( feature_enabled(local_user(), 'richtext') ) $editselect = 'textareas'; + // First day of the week (0 = Sunday) + $firstDay = get_pconfig(local_user(),'system','first_day_of_week'); + + $i18n = array( + "firstDay" => $firstDay, + "Sun" => t("Sun"), + "Mon" => t("Mon"), + "Tue" => t("Tue"), + "Wed" => t("Wed"), + "Thu" => t("Thu"), + "Fri" => t("Fri"), + "Sat" => t("Sat"), + "Sunday" => t("Sunday"), + "Monday" => t("Monday"), + "Tuesday" => t("Tuesday"), + "Wednesday" => t("Wednesday"), + "Thursday" => t("Thursday"), + "Friday" => t("Friday"), + "Saturday" => t("Saturday"), + "Jan" => t("Jan"), + "Feb" => t("Feb"), + "Mar" => t("Mar"), + "Apr" => t("Apr"), + "May" => t("May"), + "Jun" => t("Jun"), + "Jul" => t("Jul"), + "Aug" => t("Aug"), + "Sep" => t("Sept"), + "Oct" => t("Oct"), + "Nov" => t("Nov"), + "Dec" => t("Dec"), + "January" => t("January"), + "February" => t("February"), + "March" => t("March"), + "April" => t("April"), + "May" => t("May"), + "June" => t("June"), + "July" => t("July"), + "August" => t("August"), + "September" => t("September"), + "October" => t("October"), + "November" => t("November"), + "December" => t("December"), + "today" => t("today"), + "month" => t("month"), + "week" => t("week"), + "day" => t("day"), + ); + $htpl = get_markup_template('event_head.tpl'); $a->page['htmlhead'] .= replace_macros($htpl,array( '$baseurl' => $a->get_baseurl(), + '$i18n' => $i18n, '$editselect' => $editselect )); @@ -198,7 +252,8 @@ function events_content(&$a) { $o =""; // tabs - $tabs = profile_tabs($a, True); + if ($a->theme_events_in_profile) + $tabs = profile_tabs($a, True); @@ -507,7 +562,7 @@ function events_content(&$a) { '$sh_text' => t('Share this event'), '$sh_checked' => $sh_checked, '$preview' => t('Preview'), - '$acl' => (($cid) ? '' : populate_acl(((x($orig_event)) ? $orig_event : $a->user),false)), + '$acl' => (($cid) ? '' : populate_acl(((x($orig_event)) ? $orig_event : $a->user))), '$submit' => t('Submit') ));