get_option('auto-innodb'), 'true'); ?>> wp_optimize_url('https://getwpo.com/faqs/', __('Warning: you should read the FAQ about the risks of this operation first.', 'wp-optimize')); ?>

get_scheduled_optimizations(); if (!empty($auto_options)) { ?>
$event) { $div_schedule_fields_opened = false; wpo_display_event_summary($index, $event); printf(''; $div_schedule_fields_opened = false; } wpo_display_actions($index); echo '
'; } ?>

'."\n", esc_attr($index)); if (isset($event['optimization']) && is_array($event['optimization'])) wpo_display_optimization_list($event['optimization']); if (isset($event['schedule_type'])) { ?>
%s', sprintf(esc_html__('Date: %s', 'wp-optimize'), esc_html($event['date']))); } if (isset($event['time'])) { printf('%s', sprintf(esc_html__('Time: %s', 'wp-optimize'), esc_html($event['time']))); } if (isset($event['week'])) { printf('%s', sprintf(esc_html__('Week: %s', 'wp-optimize'), esc_html($event['week']))); } if (isset($event['day'])) { $week_days = WP_Optimize_Premium::get_week_days(); printf('%s', sprintf(esc_html__('Day: %s', 'wp-optimize'), esc_html($week_days[$event['day']]))); } if (isset($event['day_number'])) { printf('%s', sprintf(esc_html__('Date: %s', 'wp-optimize'), esc_html($event['day_number']))); } ?>
', esc_attr($count)); foreach ($auto_optimizations as $id => $details) { $selected = in_array($id, $optimizations) ? 'selected="selected"' : ''; $html .= sprintf('', esc_attr($id), $selected, esc_html($details['optimization'])); } $html .= ''; echo $html; } /** * Displays schedule type as select field * * @param array $schedule_type Date value * @param integer $count Index of scheduled events * * @return void */ function wpo_display_schedule_type($schedule_type, $count) { $schedule_types = WP_Optimize_Premium::get_schedule_types(); $html = ''; $html .= sprintf(''; echo $html; } /** * Displays date field * * @param string $date Date value * @param integer $count Index of scheduled events * * @return void */ function wpo_display_date($date, $count) { $today = date("Y-m-d"); $html = ''; $html .= sprintf(''; echo $html; } /** * Displays time field * * @param string $time Time value * @param integer $count Index of scheduled events * * @return void */ function wpo_display_time($time, $count) { $html = ''; $html .= sprintf(''; echo $html; } /** * Displays week select field * * @param array $week An array of 2 weeks * @param integer $count Index of scheduled events * * @return void */ function wpo_display_week($week, $count) { $weeks = array('1st' => __('1st', 'wp-optimize'), '2nd' => __('2nd', 'wp-optimize')); $html = ''; $html .= sprintf(''; echo $html; } /** * Displays week days select field * * @param array $week_day An array of week days * @param integer $count Index of scheduled events * * @return void */ function wpo_display_week_day($week_day, $count) { $week_days = WP_Optimize_Premium::get_week_days(); $html = ''; $html .= sprintf(''; echo $html; } /** * Displays days select field * * @param array $day An array of days of a month * @param integer $count Index of scheduled events * * @return void */ function wpo_display_day_number($day, $count) { $days = WP_Optimize_Premium::get_days(); $html = ''; $html .= sprintf('', esc_html__('Day Number:', 'wp-optimize')); $html .= sprintf(''; echo $html; } /** * Displays status field * * @param integer $status Status value * @param integer $count Index of scheduled events * * @return void */ function wpo_display_status($status, $count) { echo '
'; printf('', esc_attr($count), checked($status, 1, false), esc_html__('Active', 'wp-optimize')); echo '
'; } /** * Displays actions field * * @param integer $index Count of event * @param boolean $edit Boolean value to determine edit action * * @return void */ function wpo_display_actions($index, $edit = false) { printf('
', $edit ? "wpo_event_edit" : ""); if (true === $edit) { printf('%1$s', esc_html__('Edit', 'wp-optimize')); printf('%1s', esc_html__('Delete', 'wp-optimize'), esc_attr($index)); } else { printf('%1$s', esc_html__('Cancel', 'wp-optimize')); printf('%1$s', esc_html__('Apply', 'wp-optimize')); } echo '
'; } /** * Displays date field * * @param array $optimizations An array of selected optimizations * * @return void */ function wpo_display_optimization_list($optimizations) { $auto_optimizations = WP_Optimize_Premium::get_auto_optimizations(); $html = ''; $html .= ''; echo $html; }