/** * Reset the internal counter for the current day * * @return void * @see 'tribe_pre_get_template_part_pro/week/loop' */ public static function rewind_days() { self::$current_day = -1; }
/** * Return html attributes required for proper week view js functionality. * * @param int|object $event The event post, defaults to the global post. * @param string $format The format of the returned value. Can be either 'array' or 'string' * @return array|string */ function tribe_events_week_event_attributes($event = null, $format = 'string') { $attrs = Tribe__Events__Pro__Templates__Week::get_event_attributes($event); $attrs = apply_filters('tribe_events_week_event_attributes', $attrs); if ($format == 'array') { $return = $attrs; } elseif ($format == 'string') { $return = ''; foreach ($attrs as $attr => $value) { $return .= " {$attr}=" . '"' . esc_attr($value) . '"'; } } return $return; }