Version Description
- Bug fixed: Return 'Empty settings' message for pagination request
Download this release
Release Info
Developer | PT Guy |
Plugin | Content Views – Post Grid & List for WordPress |
Version | 1.3.3 |
Comparing to | |
See all releases |
Code changes from version 1.3.2 to 1.3.3
- README.txt +7 -1
- content-views.php +2 -2
- includes/functions.php +9 -3
- includes/html.php +7 -3
README.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_i
|
|
4 |
Tags: post, posts, page, pages, query, queries, search, display, show, grid, layout, author, blog, categories, category, comment, content, custom, editor, filter, Formatting, image, list, meta, plugin, responsive, shortcode, excerpt, title, tag, term, Taxonomy, thumbnail, pagination, date, scrollable, slider, collapsible
|
5 |
Requires at least: 3.3
|
6 |
Tested up to: 4.0
|
7 |
-
Stable tag: 1.3.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -142,6 +142,9 @@ You can create Unlimited Views, in Unlimited websites
|
|
142 |
|
143 |
== Changelog ==
|
144 |
|
|
|
|
|
|
|
145 |
= 1.3.2 =
|
146 |
* Update: Official refined Bootstrap version (bring here from Pro plugin)
|
147 |
* Update: Apply "Open in" setting for "Read more" button, too
|
@@ -269,6 +272,9 @@ You can create Unlimited Views, in Unlimited websites
|
|
269 |
|
270 |
== Upgrade Notice ==
|
271 |
|
|
|
|
|
|
|
272 |
= 1.3.2 =
|
273 |
Update: Official refined Bootstrap version (bring here from Pro plugin). Update: Apply "Open in" setting for "Read more" button, too. Bug fixed: Get wrong excerpt if content of post contains shortcode tags
|
274 |
|
4 |
Tags: post, posts, page, pages, query, queries, search, display, show, grid, layout, author, blog, categories, category, comment, content, custom, editor, filter, Formatting, image, list, meta, plugin, responsive, shortcode, excerpt, title, tag, term, Taxonomy, thumbnail, pagination, date, scrollable, slider, collapsible
|
5 |
Requires at least: 3.3
|
6 |
Tested up to: 4.0
|
7 |
+
Stable tag: 1.3.3
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
142 |
|
143 |
== Changelog ==
|
144 |
|
145 |
+
= 1.3.3 =
|
146 |
+
* Bug fixed: Return 'Empty settings' message for pagination request
|
147 |
+
|
148 |
= 1.3.2 =
|
149 |
* Update: Official refined Bootstrap version (bring here from Pro plugin)
|
150 |
* Update: Apply "Open in" setting for "Read more" button, too
|
272 |
|
273 |
== Upgrade Notice ==
|
274 |
|
275 |
+
= 1.3.3 =
|
276 |
+
Bug fixed: Return 'Empty settings' message for pagination request
|
277 |
+
|
278 |
= 1.3.2 =
|
279 |
Update: Official refined Bootstrap version (bring here from Pro plugin). Update: Apply "Open in" setting for "Read more" button, too. Bug fixed: Get wrong excerpt if content of post contains shortcode tags
|
280 |
|
content-views.php
CHANGED
@@ -10,7 +10,7 @@
|
|
10 |
* Plugin Name: Content Views
|
11 |
* Plugin URI: http://wordpress.org/plugins/content-views-query-and-display-post-page/
|
12 |
* Description: Query and display <strong>posts, pages</strong> in awesome layouts (<strong>grid, scrollable list, collapsible list</strong>) easier than ever, without coding!
|
13 |
-
* Version: 1.3.
|
14 |
* Author: PT Guy
|
15 |
* Author URI: http://profiles.wordpress.org/pt-guy
|
16 |
* Text Domain: content-views
|
@@ -27,7 +27,7 @@ if ( ! defined( 'WPINC' ) ) {
|
|
27 |
/*
|
28 |
* Define Constant
|
29 |
*/
|
30 |
-
define( 'PT_CV_VERSION', '1.3.
|
31 |
define( 'PT_CV_FILE', __FILE__ );
|
32 |
$pt_cv_path = plugin_dir_path( __FILE__ );
|
33 |
include_once( $pt_cv_path . 'includes/defines.php' );
|
10 |
* Plugin Name: Content Views
|
11 |
* Plugin URI: http://wordpress.org/plugins/content-views-query-and-display-post-page/
|
12 |
* Description: Query and display <strong>posts, pages</strong> in awesome layouts (<strong>grid, scrollable list, collapsible list</strong>) easier than ever, without coding!
|
13 |
+
* Version: 1.3.3
|
14 |
* Author: PT Guy
|
15 |
* Author URI: http://profiles.wordpress.org/pt-guy
|
16 |
* Text Domain: content-views
|
27 |
/*
|
28 |
* Define Constant
|
29 |
*/
|
30 |
+
define( 'PT_CV_VERSION', '1.3.3' );
|
31 |
define( 'PT_CV_FILE', __FILE__ );
|
32 |
$pt_cv_path = plugin_dir_path( __FILE__ );
|
33 |
include_once( $pt_cv_path . 'includes/defines.php' );
|
includes/functions.php
CHANGED
@@ -494,6 +494,7 @@ if ( ! class_exists( 'PT_CV_Functions' ) ) {
|
|
494 |
|
495 |
$session_id = ( $pargs && isset( $pargs['session_id'] ) ) ? $pargs['session_id'] : 0;
|
496 |
|
|
|
497 |
if ( $session_id ) {
|
498 |
$session_data = array_merge(
|
499 |
array( '$args' => '', '$dargs' => '' ),
|
@@ -503,9 +504,9 @@ if ( ! class_exists( 'PT_CV_Functions' ) ) {
|
|
503 |
$args = $session_data['$args'];
|
504 |
$dargs = $session_data['$dargs'];
|
505 |
} else {
|
506 |
-
// Generate session key for pagination
|
507 |
global $pt_view_sid;
|
508 |
-
|
|
|
509 |
|
510 |
// Store settings
|
511 |
set_transient( PT_CV_PREFIX . 'view-settings-' . $session_id, $settings, 30 * MINUTE_IN_SECONDS );
|
@@ -1107,6 +1108,11 @@ if ( ! class_exists( 'PT_CV_Functions' ) ) {
|
|
1107 |
// Get saved $settings
|
1108 |
$settings = get_transient( PT_CV_PREFIX . 'view-settings-' . $session_id );
|
1109 |
|
|
|
|
|
|
|
|
|
|
|
1110 |
// Pagination settings
|
1111 |
$pargs = array( 'session_id' => $session_id, 'page' => (int) esc_sql( $_POST['page'] ) );
|
1112 |
|
@@ -1119,7 +1125,7 @@ if ( ! class_exists( 'PT_CV_Functions' ) ) {
|
|
1119 |
}
|
1120 |
|
1121 |
// Show View output
|
1122 |
-
echo balanceTags( PT_CV_Functions::view_process_settings(
|
1123 |
|
1124 |
// Must exit
|
1125 |
die;
|
494 |
|
495 |
$session_id = ( $pargs && isset( $pargs['session_id'] ) ) ? $pargs['session_id'] : 0;
|
496 |
|
497 |
+
// If is pagination request
|
498 |
if ( $session_id ) {
|
499 |
$session_data = array_merge(
|
500 |
array( '$args' => '', '$dargs' => '' ),
|
504 |
$args = $session_data['$args'];
|
505 |
$dargs = $session_data['$dargs'];
|
506 |
} else {
|
|
|
507 |
global $pt_view_sid;
|
508 |
+
// If id is passed, assign it to session id, otherwise, generate random number
|
509 |
+
$pt_view_sid = $session_id = $id ? $id : PT_CV_Functions::string_random();
|
510 |
|
511 |
// Store settings
|
512 |
set_transient( PT_CV_PREFIX . 'view-settings-' . $session_id, $settings, 30 * MINUTE_IN_SECONDS );
|
1108 |
// Get saved $settings
|
1109 |
$settings = get_transient( PT_CV_PREFIX . 'view-settings-' . $session_id );
|
1110 |
|
1111 |
+
// If empty, get settings by ID
|
1112 |
+
if ( ! $settings ) {
|
1113 |
+
$settings = PT_CV_Functions::view_get_settings( $session_id );
|
1114 |
+
}
|
1115 |
+
|
1116 |
// Pagination settings
|
1117 |
$pargs = array( 'session_id' => $session_id, 'page' => (int) esc_sql( $_POST['page'] ) );
|
1118 |
|
1125 |
}
|
1126 |
|
1127 |
// Show View output
|
1128 |
+
echo balanceTags( PT_CV_Functions::view_process_settings( null, $settings, $pargs ) );
|
1129 |
|
1130 |
// Must exit
|
1131 |
die;
|
includes/html.php
CHANGED
@@ -455,9 +455,13 @@ if ( ! class_exists( 'PT_CV_Html' ) ) {
|
|
455 |
switch ( $fargs['content']['show'] ) {
|
456 |
case 'excerpt':
|
457 |
$length = (int) $fargs['content']['length'];
|
458 |
-
|
459 |
-
$
|
460 |
-
|
|
|
|
|
|
|
|
|
461 |
|
462 |
$content = apply_filters( PT_CV_PREFIX_ . 'field_content_result', '', $fargs, $post );
|
463 |
|
455 |
switch ( $fargs['content']['show'] ) {
|
456 |
case 'excerpt':
|
457 |
$length = (int) $fargs['content']['length'];
|
458 |
+
|
459 |
+
$readmore_btn = ' ...';
|
460 |
+
if ( apply_filters( PT_CV_PREFIX_ . 'field_content_readmore_enable', 1, $fargs['content'] ) ) {
|
461 |
+
$text = apply_filters( PT_CV_PREFIX_ . 'field_content_readmore_text', __( 'Read More', PT_CV_DOMAIN ), $fargs['content'] );
|
462 |
+
$readmore = self::_field_href( $oargs, $post, $text, PT_CV_PREFIX . 'readmore btn' );
|
463 |
+
$readmore_btn .= '<br />' . $readmore;
|
464 |
+
}
|
465 |
|
466 |
$content = apply_filters( PT_CV_PREFIX_ . 'field_content_result', '', $fargs, $post );
|
467 |
|