PluginProbe
Yatra – Travel Booking & Tour Operator Software / 3.0.7
Yatra – Travel Booking & Tour Operator Software v3.0.7
3.0.16 3.0.15 3.0.14 3.0.14.1 3.0.14.2 3.0.12 3.0.13 3.0.11 3.0.10 3.0.9 3.0.8 3.0.7 3.0.6 3.0.5 3.0.5.1 3.0.4 3.0.3 3.0.2.9 3.0.2.7 3.0.2.8 3.0.2.6 trunk 1.0.0 2.0.0 2.0.1 All 84 releases
yatra / templates / partials / single-trip / content-whats-make-special.php

content-whats-make-special.php in Yatra – Travel Booking & Tour Operator Software 3.0.7, at templates/partials/single-trip/content-whats-make-special.php

66 lines 3.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 if (!defined('ABSPATH')) {
3 exit;
4 }
5 ?>
6 <section class="yatra-trip-section" id="what-makes-special">
7 <h2 class="yatra-trip-section-title">
8 <?php yatra_render_tab_icon($tab->icon ?? null, 'star', 'yatra-trip-section-title-icon', $tab->label ?? __('What Makes This Trip Special', 'yatra')); ?>
9 <?php echo esc_html(isset($tab->label) ? $tab->label : __('What Makes This Trip Special', 'yatra')); ?>
10 </h2>
11 <div class="yatra-trip-special-container">
12 <div class="yatra-trip-special-content">
13 <div class="yatra-special-features">
14 <?php
15 $special_content = $trip->getWhatMakesSpecial() ?? '';
16 if (!empty($special_content)) {
17 // Split content by lines and create feature items
18 $features = preg_split('/\r\n|\r|\n/', $special_content);
19 $features = array_filter($features, function($line) {
20 return !empty(trim($line));
21 });
22
23 if (!empty($features)) {
24 foreach ($features as $index => $feature) {
25 $feature = trim($feature);
26 if (!empty($feature)) {
27 ?>
28 <div class="yatra-special-feature-item">
29 <div class="yatra-special-feature-icon">
30 <?php echo yatra_svg_icon('check-circle', 'yatra-feature-check'); ?>
31 </div>
32 <div class="yatra-special-feature-text">
33 <?php echo wp_kses_post($feature); ?>
34 </div>
35 </div>
36 <?php
37 }
38 }
39 } else {
40 // Fallback to simple paragraph if no line breaks
41 ?>
42 <div class="yatra-special-feature-item">
43 <div class="yatra-special-feature-icon">
44 <?php echo yatra_svg_icon('star', 'yatra-feature-check'); ?>
45 </div>
46 <div class="yatra-special-feature-text">
47 <?php echo wp_kses_post($special_content); ?>
48 </div>
49 </div>
50 <?php
51 }
52 } else {
53 echo '<p class="yatra-no-content">' . esc_html__('No special features listed for this trip yet.', 'yatra') . '</p>';
54 }
55 ?>
56 </div>
57 </div>
58
59 <?php if (!empty($special_content)): ?>
60 <div class="yatra-special-badge">
61 <?php echo yatra_svg_icon('award', 'yatra-badge-icon'); ?>
62 <span><?php echo esc_html__('Premium Experience', 'yatra'); ?></span>
63 </div>
64 <?php endif; ?>
65 </div>
66 </section>