Version Description
- Fix for Elementor rendering in legacy mode.
- Fix for Post Thumbnail display in legacy mode.
Download this release
Release Info
Developer | figureone |
Plugin | Insert Pages |
Version | 3.4.1 |
Comparing to | |
See all releases |
Code changes from version 3.4.0 to 3.4.1
- insert-pages.php +11 -2
- readme.txt +4 -0
insert-pages.php
CHANGED
@@ -7,7 +7,7 @@
|
|
7 |
* Text Domain: insert-pages
|
8 |
* Domain Path: /languages
|
9 |
* License: GPL2
|
10 |
-
* Version: 3.4.
|
11 |
*
|
12 |
* @package insert-pages
|
13 |
*/
|
@@ -670,6 +670,15 @@ if ( ! class_exists( 'InsertPagesPlugin' ) ) {
|
|
670 |
}
|
671 |
break;
|
672 |
case 'content':
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
673 |
the_post();
|
674 |
if ( $attributes['should_apply_the_content_filter'] ) {
|
675 |
the_content();
|
@@ -678,7 +687,7 @@ if ( ! class_exists( 'InsertPagesPlugin' ) ) {
|
|
678 |
}
|
679 |
break;
|
680 |
case 'post-thumbnail':
|
681 |
-
?><a href="<?php
|
682 |
<?php
|
683 |
break;
|
684 |
case 'all':
|
7 |
* Text Domain: insert-pages
|
8 |
* Domain Path: /languages
|
9 |
* License: GPL2
|
10 |
+
* Version: 3.4.1
|
11 |
*
|
12 |
* @package insert-pages
|
13 |
*/
|
670 |
}
|
671 |
break;
|
672 |
case 'content':
|
673 |
+
// If Elementor is installed, try to render the page with it. If there is no Elementor content, fall back to normal rendering.
|
674 |
+
if ( class_exists( '\Elementor\Plugin' ) ) {
|
675 |
+
$elementor_content = \Elementor\Plugin::$instance->frontend->get_builder_content( $inserted_page->ID );
|
676 |
+
if ( strlen( $elementor_content ) > 0 ) {
|
677 |
+
echo $elementor_content;
|
678 |
+
break;
|
679 |
+
}
|
680 |
+
}
|
681 |
+
// Render the content normally.
|
682 |
the_post();
|
683 |
if ( $attributes['should_apply_the_content_filter'] ) {
|
684 |
the_content();
|
687 |
}
|
688 |
break;
|
689 |
case 'post-thumbnail':
|
690 |
+
?><a href="<?php echo esc_url( get_permalink( $inserted_page->ID ) ); ?>"><?php echo get_the_post_thumbnail( $inserted_page->ID ); ?></a>
|
691 |
<?php
|
692 |
break;
|
693 |
case 'all':
|
readme.txt
CHANGED
@@ -86,6 +86,10 @@ Just one! The plugin prevents you from embedding a page in itself, but you can t
|
|
86 |
|
87 |
== Changelog ==
|
88 |
|
|
|
|
|
|
|
|
|
89 |
= 3.4.0 =
|
90 |
* Add integration with WPBakery Page Builder (Visual Composer).
|
91 |
* Fix error messages about deprecated functions in PHP 7.2.
|
86 |
|
87 |
== Changelog ==
|
88 |
|
89 |
+
= 3.4.1 =
|
90 |
+
* Fix for Elementor rendering in legacy mode.
|
91 |
+
* Fix for Post Thumbnail display in legacy mode.
|
92 |
+
|
93 |
= 3.4.0 =
|
94 |
* Add integration with WPBakery Page Builder (Visual Composer).
|
95 |
* Fix error messages about deprecated functions in PHP 7.2.
|