PluginProbe
Fluent Booking – The Ultimate Appointments Scheduling, Events Booking, Events Calendar Solution / 2.5.0
Fluent Booking – The Ultimate Appointments Scheduling, Events Booking, Events Calendar Solution v2.5.0
2.5.0 2.4.0 2.3.0 2.2.5 2.2.0 2.1.2 2.1.1 trunk 1.10.0 1.10.01 1.10.02 1.5.0 1.5.01 1.5.02 1.5.1 1.5.10 1.5.20 1.5.21 1.5.22 1.5.23 1.5.24 1.5.25 1.6.0 1.7.0 1.7.1 All 34 releases
← All changes | app/Views/landing/author_landing.php +31 -13 1.7.0 → 2.5.0 View file →
@@ -1,6 +1,24 @@
1 -<?php defined( 'ABSPATH' ) || exit; ?>
1 +<?php
2 +defined( 'ABSPATH' ) || exit;
2 3
4 +use FluentBooking\App\Models\Calendar;
5 +
6 +/**
7 + * @var Calendar $calendar
8 + * @var iterable $events
9 + * @var array $author
10 + * @var string $title
11 + * @var string $description
12 + * @var string $url
13 + * @var bool $embedded
14 + * @var array $css_files
15 + * @var array $js_files
16 + * @var array $js_vars
17 + * @var array $header_js_files
18 + */
19 +?>
20 +
3 21 <!DOCTYPE html>
4 22 <html <?php language_attributes(); ?>>
5 23 <head>
6 24 <title><?php echo esc_attr($title); ?></title>
@@ -25,12 +43,11 @@
25 43 ?>
26 44 <meta property="og:image" content="<?php echo esc_url($author['featured_image']); ?>"/>
27 45 <?php } ?>
28 46
29 - <?php foreach ($css_files as $css_file): ?>
30 - <link rel="stylesheet"
31 - href="<?php echo esc_url($css_file); ?>?version=<?php echo esc_html(FLUENT_BOOKING_ASSETS_VERSION); ?>"
32 - media="screen"/>
47 + <?php foreach ($css_files as $fluentBookingCssFile): ?>
48 + <?php // phpcs:ignore WordPress.WP.EnqueuedResources.NonEnqueuedStylesheet ?>
49 + <link rel="stylesheet" href="<?php echo esc_url($fluentBookingCssFile); ?>?version=<?php echo esc_html(FLUENT_BOOKING_ASSETS_VERSION); ?>" media="screen"/>
33 50 <?php endforeach; ?>
34 51
35 52 <style>
36 53 :root {
@@ -59,10 +76,10 @@
59 76 background-size: 100%;
60 77 }
61 78 </style>
62 79
63 - <?php foreach ($header_js_files as $fileKey => $file): ?>
64 - <script id="<?php echo esc_attr($fileKey); ?>" src="<?php echo esc_url($file); ?>?version=<?php echo esc_attr(FLUENT_BOOKING_ASSETS_VERSION); ?>"></script>
80 + <?php foreach ($header_js_files as $fluentBookingFileKey => $fluentBookingFile): ?>
81 + <script id="<?php echo esc_attr($fluentBookingFileKey); ?>"<?php echo \FluentBooking\App\Vite::isDev() ? ' type="module"' : ''; ?> src="<?php echo esc_url($fluentBookingFile); ?>?version=<?php echo esc_attr(FLUENT_BOOKING_ASSETS_VERSION); ?>"></script>
65 82 <?php endforeach; ?>
66 83
67 84 <?php do_action('fluent_booking/main_landing'); ?>
68 85 </head>
@@ -67,23 +84,24 @@
67 84 <?php do_action('fluent_booking/main_landing'); ?>
68 85 </head>
69 86 <body>
70 87 <?php \FluentBooking\App\App::getInstance('view')->render('landing.author_html', [
71 - 'author' => $author,
88 + 'author' => $author,
72 89 'calendar' => $calendar,
73 - 'events' => $events
90 + 'events' => $events,
91 + 'embedded' => $embedded
74 92 ]); ?>
75 93 </div>
76 94 </div>
77 95
78 96 <script>
79 - <?php foreach ($js_vars as $varKey => $values): ?>
80 - var <?php echo esc_attr($varKey); ?> = <?php echo wp_json_encode($values); ?>;
97 + <?php foreach ($js_vars as $fluentBookingVarKey => $fluentBookingValues): ?>
98 + var <?php echo esc_attr($fluentBookingVarKey); ?> = <?php echo wp_json_encode($fluentBookingValues); ?>;
81 99 <?php endforeach; ?>
82 100 </script>
83 101
84 - <?php foreach ($js_files as $fileKey => $file): ?>
85 - <script id="<?php echo esc_attr($fileKey); ?>" src="<?php echo esc_url($file); ?>?version=<?php echo esc_attr(FLUENT_BOOKING_ASSETS_VERSION); ?>" defer="defer"></script>
102 + <?php foreach ($js_files as $fluentBookingFileKey => $fluentBookingFile): ?>
103 + <script id="<?php echo esc_attr($fluentBookingFileKey); ?>"<?php echo \FluentBooking\App\Vite::isDev() ? ' type="module"' : ''; ?> src="<?php echo esc_url($fluentBookingFile); ?>?version=<?php echo esc_attr(FLUENT_BOOKING_ASSETS_VERSION); ?>" defer="defer"></script>
86 104 <?php endforeach; ?>
87 105
88 106 <?php do_action('fluent_booking/main_landing_footer'); ?>
89 107 </body>