ID); $these_roles = $user->roles; $tc = new AIO_Time_Clock_Lite_Actions(); if (function_exists('is_plugin_active')) { if (is_plugin_active('aio-timeclock-google-analytics/aio-timeclock-google-analytics.php')) { aio_google_show_code(); } } //load options $widgettitle = get_option('aio_time_clock_widget_title'); //widget output echo stripslashes($args['before_widget']); echo stripslashes($args['before_title']); echo stripslashes($widgettitle); echo stripslashes($args['after_title']); echo ''; echo '
'; if (is_user_logged_in()) { if ($tc->checkPermission($these_roles)) { $this->getTimeClockWidget(); } else { echo '

' . __('Your user group does not have permission to view the Time Clock.', 'aio-time-clock') . '

'; } } else { echo '

' . __('Time Clock is only available for users that are logged in') . '

'; echo '' . __('Login', 'aio-time-clock') . ''; } echo '
'; echo ''; //close div.textwidget echo stripslashes($args['after_widget']); } function update( $new_instance, $old_instance ) { // Save widget options // Output admin widget options form if (isset($_POST['aio_widget_submitted'])) { update_option('aio_time_clock_lite_widget_title', $_POST['aio_tc_lite_widgettitle']); } } function form( $instance ) { $widgettitle = get_option('aio_time_clock_lite_widget_title'); ?>
: