PluginProbe ʕ •ᴥ•ʔ
The Post Grid – Shortcode, Gutenberg Blocks and Elementor Addon for Post Grid / 4.2.0
The Post Grid – Shortcode, Gutenberg Blocks and Elementor Addon for Post Grid v4.2.0
7.9.3 7.9.2 trunk 4.0.0 4.0.1 4.0.2 4.0.3 4.0.4 4.0.5 4.1.0 4.1.1 4.1.2 4.1.3 4.1.4 4.1.5 4.2.0 4.2.1 4.2.2 4.2.3 5.0.0 5.0.1 5.0.2 5.0.3 5.0.4 5.0.5 6.0.0 7.0.0 7.0.1 7.0.2 7.1.0 7.2.0 7.2.1 7.2.10 7.2.11 7.2.2 7.2.3 7.2.4 7.2.5 7.2.6 7.2.7 7.2.8 7.2.9 7.3.0 7.3.1 7.4.0 7.4.1 7.4.2 7.4.3 7.5.0 7.6.0 7.6.1 7.7.0 7.7.1 7.7.10 7.7.11 7.7.12 7.7.13 7.7.14 7.7.15 7.7.16 7.7.17 7.7.18 7.7.19 7.7.2 7.7.20 7.7.21 7.7.22 7.7.3 7.7.4 7.7.5 7.7.6 7.7.7 7.7.8 7.7.9 7.8.0 7.8.1 7.8.2 7.8.3 7.8.4 7.8.5 7.8.6 7.8.7 7.8.8 7.8.9 7.9.0 7.9.1
the-post-grid / templates / elementor / grid_hover-layout3.php
the-post-grid / templates / elementor Last commit date
grid-layout1.php 3 years ago grid-layout3.php 3 years ago grid-layout4.php 3 years ago grid_hover-layout1.php 3 years ago grid_hover-layout2.php 3 years ago grid_hover-layout3.php 3 years ago list-layout1.php 3 years ago list-layout2.php 3 years ago list-layout3.php 3 years ago
grid_hover-layout3.php
129 lines
1 <?php
2 /**
3 * Grid Hover Layout Template - 3
4 *
5 * @package RT_TPG
6 */
7
8 use RT\ThePostGrid\Helpers\Fns;
9
10 // Do not allow directly accessing this file.
11 if ( ! defined( 'ABSPATH' ) ) {
12 exit( 'This script cannot be accessed directly.' );
13 }
14
15 $pID = get_the_ID();
16 $excerpt = Fns::get_the_excerpt( $pID, $data );
17 $title = Fns::get_the_title( $pID, $data );
18
19 if ( 'custom' !== $data['title_visibility_style'] ) {
20 $title = get_the_title();
21 }
22 /**
23 * Get post link markup
24 * $link_start, $link_end, $readmore_link_start, $readmore_link_end
25 */
26
27 $post_link = Fns::get_post_link( $pID, $data );
28 extract( $post_link );
29
30 // Grid Column:
31 $gird_column_desktop = '0' !== $data['gird_column'] ? $data['gird_column'] : '4';
32 $gird_column_tab = '0' !== $data['gird_column_tablet'] ? $data['gird_column_tablet'] : '6';
33 $gird_column_mobile = '0' !== $data['gird_column_mobile'] ? $data['gird_column_mobile'] : '12';
34 $col_class = "rt-col-md-{$gird_column_desktop} rt-col-sm-{$gird_column_tab} rt-col-xs-{$gird_column_mobile}";
35
36 // Column Dynamic Class
37 $column_classes = [];
38
39 $column_classes[] .= $data['hover_animation'];
40 $column_classes[] .= 'rt-grid-hover-item rt-grid-item';
41 if ( 'masonry' == $data['layout_style'] ) {
42 $column_classes[] .= 'masonry-grid-item';
43 }
44
45 ?>
46
47 <div class="<?php echo esc_attr( $col_class . ' ' . implode( ' ', $column_classes ) ); ?>" data-id="<?php echo esc_attr( $pID ); ?>">
48 <div class="rt-holder tpg-post-holder">
49 <div class="rt-detail rt-el-content-wrapper">
50 <?php
51 if ( 'show' == $data['show_thumb'] ) :
52 $has_thumbnail = has_post_thumbnail() ? 'has-thumbnail' : 'has-no-thumbnail';
53 ?>
54 <div class="rt-img-holder tpg-el-image-wrap <?php echo esc_attr( $has_thumbnail ); ?>">
55 <?php Fns::get_post_thumbnail( $pID, $data, $link_start, $link_end ); ?>
56 </div>
57 <?php endif; ?>
58
59 <div class="grid-hover-content">
60
61 <?php
62 if ( 'show' == $data['show_title'] ) {
63 Fns::get_el_post_title( $data['title_tag'], $title, $link_start, $link_end, $data );
64 }
65 ?>
66
67
68 <?php if ( 'show' == $data['show_meta'] ) : ?>
69 <div class="post-meta-tags rt-el-post-meta">
70 <?php Fns::get_post_meta_html( $pID, $data ); ?>
71 </div>
72 <?php endif; ?>
73
74 <?php if ( 'show' == $data['show_excerpt'] || 'show' == $data['show_acf'] ) : ?>
75 <div class="tpg-excerpt tpg-el-excerpt">
76 <?php if ( $excerpt && 'show' == $data['show_excerpt'] ) : ?>
77 <div class="tpg-excerpt-inner">
78 <?php echo wp_kses_post( $excerpt ); ?>
79 </div>
80 <?php endif; ?>
81 <?php Fns::tpg_get_acf_data_elementor( $data, $pID ); ?>
82 </div>
83 <?php endif; ?>
84
85 <?php
86 if ( rtTPG()->hasPro() && 'show' === $data['show_social_share'] ) {
87 echo wp_kses( \RT\ThePostGridPro\Helpers\Functions::rtShare( $pID ), Fns::allowedHtml() );
88 }
89 ?>
90
91
92 <?php if ( 'show' === $data['show_read_more'] ) : ?>
93 <div class="post-footer">
94 <div class="read-more">
95 <?php
96 echo wp_kses( $readmore_link_start, Fns::allowedHtml() );
97
98 if ( 'yes' == $data['show_btn_icon'] && 'left' == $data['readmore_icon_position'] ) {
99 \Elementor\Icons_Manager::render_icon(
100 $data['readmore_btn_icon'],
101 [
102 'aria-hidden' => 'true',
103 'class' => 'left-icon',
104 ]
105 );
106 }
107
108 echo esc_html( $data['read_more_label'] );
109
110 if ( 'yes' == $data['show_btn_icon'] && 'right' == $data['readmore_icon_position'] ) {
111 \Elementor\Icons_Manager::render_icon(
112 $data['readmore_btn_icon'],
113 [
114 'aria-hidden' => 'true',
115 'class' => 'right-icon',
116 ]
117 );
118 }
119
120 echo wp_kses( $readmore_link_end, Fns::allowedHtml() );
121 ?>
122 </div>
123 </div>
124 <?php endif; ?>
125 </div>
126 </div>
127 </div>
128 </div>
129