From 08a1b8fad0d8efde3f71d39e205111d4dddd8c20 Mon Sep 17 00:00:00 2001 From: Hash9 Date: Mon, 3 Jul 2006 21:27:25 +0000 Subject: allow modules to define their own user preference tabs --- modules/userprefs.php | 12 ++++++++++++ modules/userprefs.tpl | 3 +++ 2 files changed, 15 insertions(+) create mode 100644 modules/userprefs.php create mode 100644 modules/userprefs.tpl diff --git a/modules/userprefs.php b/modules/userprefs.php new file mode 100644 index 0000000..294b914 --- /dev/null +++ b/modules/userprefs.php @@ -0,0 +1,12 @@ +isFeatureActive('calendar_user_prefs') ) { + include_once( CALENDAR_PKG_PATH.'admin/admin_calendar_inc.php' ); + if( !empty( $_REQUEST['calendar_submit'] ) ) { + foreach( $calendarValues as $item ) { + if( !empty( $_REQUEST[$item] ) ) { + $editUser->storePreference( $item, $_REQUEST[$item], 'calendar' ); + } + } + } +} +?> \ No newline at end of file diff --git a/modules/userprefs.tpl b/modules/userprefs.tpl new file mode 100644 index 0000000..ff7e264 --- /dev/null +++ b/modules/userprefs.tpl @@ -0,0 +1,3 @@ +{if $gBitSystem->isFeatureActive('calendar_user_prefs') } + {include file='bitpackage:calendar/calendar_preferences_inc.tpl' settings=$userPrefs} +{/if} \ No newline at end of file -- cgit v1.3