Version Description
- Update: Able to check/uncheck to allow HTML tags in excerpt (to preventing broken HTML output)
Download this release
Release Info
Developer | PT Guy |
Plugin | Content Views – Post Grid & List for WordPress |
Version | 1.4.9 |
Comparing to | |
See all releases |
Code changes from version 1.4.8 to 1.4.9
- README.txt +5 -2
- admin/assets/css/admin.css +4 -0
- admin/assets/images/features/collapsible.png +0 -0
- admin/assets/images/features/drag_drop.png +0 -0
- admin/assets/images/features/font-settings.png +0 -0
- admin/assets/images/features/openin.png +0 -0
- admin/assets/images/features/pagination.png +0 -0
- admin/assets/images/features/pinterest.png +0 -0
- admin/assets/images/features/readmore.png +0 -0
- admin/assets/images/features/scrollable.png +0 -0
- admin/assets/images/features/timeline.png +0 -0
- admin/assets/images/features/woocommerce.png +0 -0
- admin/includes/templates/settings-section-two.php +32 -111
- content-views.php +2 -2
- includes/functions.php +6 -3
- includes/settings.php +22 -0
- public/assets/css/public.css +2 -2
- public/content-views.php +1 -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.1
|
7 |
-
Stable tag: 1.4.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -144,11 +144,14 @@ You can create Unlimited Views, in Unlimited websites
|
|
144 |
|
145 |
== Changelog ==
|
146 |
|
|
|
|
|
|
|
147 |
= 1.4.8 =
|
148 |
* Bug fixed: Some code appears in excerpt
|
149 |
|
150 |
= 1.4.6 =
|
151 |
-
* Improvement: Allow some HTML tags (a, br, strong, em, i, ul, ol, li) in excerpt
|
152 |
* Update: Exclude Views from front-end search results
|
153 |
|
154 |
= 1.4.5 =
|
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.1
|
7 |
+
Stable tag: 1.4.9
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
144 |
|
145 |
== Changelog ==
|
146 |
|
147 |
+
= 1.4.9 =
|
148 |
+
* Update: Able to check/uncheck to allow HTML tags in excerpt (to preventing broken HTML output)
|
149 |
+
|
150 |
= 1.4.8 =
|
151 |
* Bug fixed: Some code appears in excerpt
|
152 |
|
153 |
= 1.4.6 =
|
154 |
+
* Improvement: Allow some HTML tags (a, br, strong, em, strike, i, ul, ol, li) in excerpt
|
155 |
* Update: Exclude Views from front-end search results
|
156 |
|
157 |
= 1.4.5 =
|
admin/assets/css/admin.css
CHANGED
@@ -95,6 +95,10 @@ html {
|
|
95 |
width: 100px !important;
|
96 |
}
|
97 |
|
|
|
|
|
|
|
|
|
98 |
/* Group type */
|
99 |
.panel-group .pt-cv-group {
|
100 |
margin-top: 10px;
|
95 |
width: 100px !important;
|
96 |
}
|
97 |
|
98 |
+
.pt-cv-full-fields .checkbox {
|
99 |
+
width: 100% !important;
|
100 |
+
}
|
101 |
+
|
102 |
/* Group type */
|
103 |
.panel-group .pt-cv-group {
|
104 |
margin-top: 10px;
|
admin/assets/images/features/collapsible.png
DELETED
Binary file
|
admin/assets/images/features/drag_drop.png
DELETED
Binary file
|
admin/assets/images/features/font-settings.png
DELETED
Binary file
|
admin/assets/images/features/openin.png
DELETED
Binary file
|
admin/assets/images/features/pagination.png
DELETED
Binary file
|
admin/assets/images/features/pinterest.png
DELETED
Binary file
|
admin/assets/images/features/readmore.png
DELETED
Binary file
|
admin/assets/images/features/scrollable.png
DELETED
Binary file
|
admin/assets/images/features/timeline.png
DELETED
Binary file
|
admin/assets/images/features/woocommerce.png
DELETED
Binary file
|
admin/includes/templates/settings-section-two.php
CHANGED
@@ -1,133 +1,54 @@
|
|
1 |
<hr>
|
2 |
-
<p>Here is list of some of awesome features which are available at
|
3 |
-
<a href="http://www.contentviewspro.com/?utm_source=settings_page&utm_medium=link&utm_campaign=content-views" target="_blank">Content Views PRO</a>
|
4 |
-
</p>
|
5 |
|
6 |
-
<
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
|
|
11 |
|
12 |
-
<
|
13 |
-
<div class="col-md-6">
|
14 |
-
<h3>
|
15 |
-
Query custom post types
|
16 |
-
</h3>
|
17 |
|
18 |
-
|
19 |
-
<p>You can get any posts of any custom post types (<strong>WooCommerce</strong> product, FAQ, Book...)</p>
|
20 |
-
|
21 |
-
<p>Especially, with <strong>WooCommerce</strong>, there are quick filters to pick up</p>
|
22 |
-
<ul style="list-style: circle; margin-left: 20px;">
|
23 |
-
<li>Recent products</li>
|
24 |
-
<li>Best selling products</li>
|
25 |
-
<li>Features products</li>
|
26 |
-
<li>Top rated products</li>
|
27 |
-
</ul>
|
28 |
-
easily
|
29 |
-
</div>
|
30 |
-
</div>
|
31 |
<div class="col-md-6">
|
32 |
-
<div>
|
33 |
-
<img src="<?php echo esc_url( plugins_url( 'admin/assets/images/features/woocommerce.png', PT_CV_FILE ) ); ?>" />
|
34 |
-
</div>
|
35 |
-
</div>
|
36 |
-
</div>
|
37 |
-
|
38 |
-
<hr>
|
39 |
-
|
40 |
-
<div class="row">
|
41 |
-
<div class="col-md-12">
|
42 |
<h3>
|
43 |
More beautiful & awesome layouts
|
44 |
</h3>
|
45 |
-
|
46 |
<div>
|
47 |
-
<
|
48 |
-
<
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
</div>
|
55 |
-
<div class="col-md-6">
|
56 |
-
<h6>Collapsible list</h6>
|
57 |
-
|
58 |
-
<div>
|
59 |
-
<img class="thumbnail" src="<?php echo esc_url( plugins_url( 'admin/assets/images/features/collapsible.png', PT_CV_FILE ) ); ?>" />
|
60 |
-
</div>
|
61 |
-
</div>
|
62 |
-
</div>
|
63 |
-
<div class="row">
|
64 |
-
<div class="col-md-6">
|
65 |
-
<h6>Pinterest</h6>
|
66 |
-
|
67 |
-
<div>
|
68 |
-
<img class="thumbnail" src="<?php echo esc_url( plugins_url( 'admin/assets/images/features/pinterest.png', PT_CV_FILE ) ); ?>" />
|
69 |
-
</div>
|
70 |
-
</div>
|
71 |
-
<div class="col-md-6">
|
72 |
-
<h6>Timeline</h6>
|
73 |
-
|
74 |
-
<div>
|
75 |
-
<img class="thumbnail" src="<?php echo esc_url( plugins_url( 'admin/assets/images/features/timeline.png', PT_CV_FILE ) ); ?>" />
|
76 |
-
</div>
|
77 |
-
</div>
|
78 |
-
</div>
|
79 |
-
</div>
|
80 |
-
</div>
|
81 |
-
</div>
|
82 |
-
|
83 |
-
<hr>
|
84 |
-
|
85 |
-
<div class="row">
|
86 |
-
<div class="col-md-6">
|
87 |
-
<h3>
|
88 |
-
Drag & drop to change display order of fields
|
89 |
-
</h3>
|
90 |
-
|
91 |
-
<div>
|
92 |
-
<img class="thumbnail" src="<?php echo esc_url( plugins_url( 'admin/assets/images/features/drag_drop.png', PT_CV_FILE ) ); ?>" />
|
93 |
</div>
|
94 |
</div>
|
|
|
95 |
<div class="col-md-6">
|
96 |
<h3>
|
97 |
-
|
98 |
</h3>
|
99 |
-
|
100 |
<div>
|
101 |
-
<
|
|
|
|
|
|
|
|
|
|
|
|
|
102 |
</div>
|
103 |
</div>
|
|
|
|
|
|
|
104 |
</div>
|
105 |
|
106 |
-
<
|
107 |
-
|
108 |
-
|
109 |
-
<
|
110 |
-
|
111 |
-
Custom font settings
|
112 |
-
</h3>
|
113 |
-
|
114 |
-
<div>
|
115 |
-
<p>You can customize Font family (from top 50 most popular Google fonts), font style, font size for Title, Content, Meta fields easily</p>
|
116 |
-
<img class="thumbnail" src="<?php echo esc_url( plugins_url( 'admin/assets/images/features/font-settings.png', PT_CV_FILE ) ); ?>" style="height: 210px;" />
|
117 |
-
</div>
|
118 |
-
</div>
|
119 |
-
<div class="col-md-6">
|
120 |
-
<h3>
|
121 |
-
And more powerful options
|
122 |
-
</h3>
|
123 |
-
|
124 |
-
<div>
|
125 |
-
<img class="thumbnail" src="<?php echo esc_url( plugins_url( 'admin/assets/images/features/pagination.png', PT_CV_FILE ) ); ?>" />
|
126 |
-
<img class="thumbnail" src="<?php echo esc_url( plugins_url( 'admin/assets/images/features/openin.png', PT_CV_FILE ) ); ?>" />
|
127 |
-
<br> <span style="font-size: 30px;">...</span>
|
128 |
-
</div>
|
129 |
-
</div>
|
130 |
-
</div>
|
131 |
|
132 |
<hr>
|
133 |
|
1 |
<hr>
|
|
|
|
|
|
|
2 |
|
3 |
+
<style>
|
4 |
+
#pt-cv-features {padding-right: 0; margin-bottom: 30px;}
|
5 |
+
#pt-cv-features * {font-size: 14px;}
|
6 |
+
#pt-cv-features h3 {font-size: 18px;}
|
7 |
+
#pt-cv-features .col-md-6 {padding: 0;}
|
8 |
+
</style>
|
9 |
|
10 |
+
<h2>Want more powerful features?</h2>
|
|
|
|
|
|
|
|
|
11 |
|
12 |
+
<div class="col-md-12" id="pt-cv-features">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
13 |
<div class="col-md-6">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
14 |
<h3>
|
15 |
More beautiful & awesome layouts
|
16 |
</h3>
|
|
|
17 |
<div>
|
18 |
+
<ul style="list-style: circle; margin-left: 20px;">
|
19 |
+
<li>Grid </li>
|
20 |
+
<li>Pinterest </li>
|
21 |
+
<li>Timeline </li>
|
22 |
+
<li>Scrollable/Slider list </li>
|
23 |
+
<li>Collapsible list</li>
|
24 |
+
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
25 |
</div>
|
26 |
</div>
|
27 |
+
|
28 |
<div class="col-md-6">
|
29 |
<h3>
|
30 |
+
Query custom post types
|
31 |
</h3>
|
|
|
32 |
<div>
|
33 |
+
<p>Content Views Pro allows you to query any custom post types.</p>
|
34 |
+
<p>And of course, It supports below well-known plugins:</p>
|
35 |
+
<ul style="list-style: circle; margin-left: 20px;">
|
36 |
+
<li>WooCommerce</li>
|
37 |
+
<li>Easy Digital Downloads</li>
|
38 |
+
<li>Advanced Custom Fields</li>
|
39 |
+
</ul>
|
40 |
</div>
|
41 |
</div>
|
42 |
+
|
43 |
+
<a style="font-size: 18px;" href="http://sample.contentviewspro.com/?utm_source=client&utm_medium=view" target="_blank">See all features</a>
|
44 |
+
<br>
|
45 |
</div>
|
46 |
|
47 |
+
<p style="margin-top: 20px;">
|
48 |
+
<a href="http://www.contentviewspro.com/pricing/?utm_source=settings_page&utm_medium=link&utm_campaign=content-views" target="_blank" class="btn btn-success">Upgrade now</a>
|
49 |
+
or
|
50 |
+
<a href="http://sample.contentviewspro.com/?utm_source=client&utm_medium=view" target="_blank" class="btn btn-info">Check demo site</a>
|
51 |
+
</p>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
52 |
|
53 |
<hr>
|
54 |
|
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.4.
|
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.4.
|
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.4.9
|
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.4.9' );
|
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
@@ -202,8 +202,11 @@ if ( ! class_exists( 'PT_CV_Functions' ) ) {
|
|
202 |
*/
|
203 |
static function pt_strip_tags( $string ) {
|
204 |
$string = preg_replace( '@<(script|style)[^>]*?>.*?</\\1>@si', '', $string );
|
|
|
205 |
# allow some tags
|
206 |
-
|
|
|
|
|
207 |
|
208 |
return trim( $string );
|
209 |
}
|
@@ -556,7 +559,7 @@ if ( ! class_exists( 'PT_CV_Functions' ) ) {
|
|
556 |
$pt_view_sid = $session_id = $id ? $id : PT_CV_Functions::string_random();
|
557 |
|
558 |
// Store settings
|
559 |
-
set_transient( PT_CV_PREFIX . 'view-settings-' . $session_id, $settings,
|
560 |
}
|
561 |
|
562 |
if ( empty( $args ) || empty( $dargs ) ) {
|
@@ -573,7 +576,7 @@ if ( ! class_exists( 'PT_CV_Functions' ) ) {
|
|
573 |
array(
|
574 |
'$args' => $args,
|
575 |
'$dargs' => $dargs,
|
576 |
-
),
|
577 |
);
|
578 |
}
|
579 |
|
202 |
*/
|
203 |
static function pt_strip_tags( $string ) {
|
204 |
$string = preg_replace( '@<(script|style)[^>]*?>.*?</\\1>@si', '', $string );
|
205 |
+
|
206 |
# allow some tags
|
207 |
+
global $dargs;
|
208 |
+
$allowed_tags = ! empty( $dargs['field-settings']['content']['allow_html'] ) ? '<a><br><strong><em><strike><i><ul><ol><li>' : '';
|
209 |
+
$string = strip_tags( $string, $allowed_tags );
|
210 |
|
211 |
return trim( $string );
|
212 |
}
|
559 |
$pt_view_sid = $session_id = $id ? $id : PT_CV_Functions::string_random();
|
560 |
|
561 |
// Store settings
|
562 |
+
set_transient( PT_CV_PREFIX . 'view-settings-' . $session_id, $settings, 7 * DAY_IN_SECONDS );
|
563 |
}
|
564 |
|
565 |
if ( empty( $args ) || empty( $dargs ) ) {
|
576 |
array(
|
577 |
'$args' => $args,
|
578 |
'$dargs' => $dargs,
|
579 |
+
), 7 * DAY_IN_SECONDS
|
580 |
);
|
581 |
}
|
582 |
|
includes/settings.php
CHANGED
@@ -344,6 +344,28 @@ if ( ! class_exists( 'PT_CV_Settings' ) ) {
|
|
344 |
),
|
345 |
),
|
346 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
347 |
),
|
348 |
$prefix . 'excerpt-'
|
349 |
),
|
344 |
),
|
345 |
),
|
346 |
),
|
347 |
+
|
348 |
+
// Allow HTML tags
|
349 |
+
array(
|
350 |
+
'label' => array(
|
351 |
+
'text' => '',
|
352 |
+
),
|
353 |
+
'extra_setting' => array(
|
354 |
+
'params' => array(
|
355 |
+
'wrap-class' => PT_CV_PREFIX . 'full-fields',
|
356 |
+
'width' => 9,
|
357 |
+
),
|
358 |
+
),
|
359 |
+
'params' => array(
|
360 |
+
array(
|
361 |
+
'type' => 'checkbox',
|
362 |
+
'name' => $prefix . 'excerpt-allow_html',
|
363 |
+
'options' => PT_CV_Values::yes_no( 'yes', __( 'Allow HTML tags (a, br, strong, em, strike, i, ul, ol, li) in excerpt', PT_CV_DOMAIN ) ),
|
364 |
+
'std' => '',
|
365 |
+
'desc' => __( 'This option can cause broken HTML output. Please be careful when check it', PT_CV_DOMAIN ),
|
366 |
+
),
|
367 |
+
),
|
368 |
+
),
|
369 |
),
|
370 |
$prefix . 'excerpt-'
|
371 |
),
|
public/assets/css/public.css
CHANGED
@@ -124,11 +124,11 @@
|
|
124 |
margin: 0 auto !important;
|
125 |
}
|
126 |
|
127 |
-
.pagination > li {
|
128 |
background: none !important;
|
129 |
}
|
130 |
|
131 |
-
.pagination > li > a {
|
132 |
cursor: pointer;
|
133 |
}
|
134 |
|
124 |
margin: 0 auto !important;
|
125 |
}
|
126 |
|
127 |
+
.pt-cv-view + .pagination > li {
|
128 |
background: none !important;
|
129 |
}
|
130 |
|
131 |
+
.pt-cv-view + .pagination > li > a {
|
132 |
cursor: pointer;
|
133 |
}
|
134 |
|
public/content-views.php
CHANGED
@@ -265,9 +265,7 @@ class PT_Content_Views {
|
|
265 |
|
266 |
$args = array(
|
267 |
'labels' => $labels,
|
268 |
-
'public' =>
|
269 |
-
'publicly_queryable' => true,
|
270 |
-
'exclude_from_search' => true, #exclude posts with this post type from front end search results
|
271 |
|
272 |
// Hide in menu, but can see All Views page
|
273 |
'show_ui' => false,
|
265 |
|
266 |
$args = array(
|
267 |
'labels' => $labels,
|
268 |
+
'public' => false,
|
|
|
|
|
269 |
|
270 |
// Hide in menu, but can see All Views page
|
271 |
'show_ui' => false,
|