Version Description
Download this release
Release Info
Developer | ZephyrWest |
Plugin | Category Posts Widget |
Version | 1.3.3 |
Comparing to | |
See all releases |
Code changes from version 1.3.2 to 1.3.3
- cat-posts.php +8 -5
- readme.txt +3 -3
cat-posts.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<?php
|
2 |
/*
|
3 |
Plugin Name: Category Posts Widget
|
4 |
-
Plugin URI: http://jameslao.com/
|
5 |
Description: Adds a widget that can display a specified number of posts from a single category. Can also set how many widgets to show.
|
6 |
Author: James Lao
|
7 |
-
Version: 1.3.
|
8 |
-
Author URI: http://jameslao.com/
|
9 |
*/
|
10 |
|
11 |
// Displays widget on blag
|
@@ -55,7 +55,10 @@ function jl_cat_posts_widget( $args, $widget_args = 1 ) {
|
|
55 |
echo '<li class="cat-posts-item-' . $post->ID . '"><a href="' . get_permalink($post) . '">' . $post->post_title . '</a>';
|
56 |
if( $excerpt ) {
|
57 |
echo '<br />';
|
58 |
-
|
|
|
|
|
|
|
59 |
}
|
60 |
echo '</li>';
|
61 |
}
|
@@ -204,4 +207,4 @@ function jl_cat_posts_register() {
|
|
204 |
// This is important
|
205 |
add_action( 'widgets_init', 'jl_cat_posts_register' );
|
206 |
|
207 |
-
?>
|
1 |
<?php
|
2 |
/*
|
3 |
Plugin Name: Category Posts Widget
|
4 |
+
Plugin URI: http://jameslao.com/2008/04/18/category-posts-widget-13/
|
5 |
Description: Adds a widget that can display a specified number of posts from a single category. Can also set how many widgets to show.
|
6 |
Author: James Lao
|
7 |
+
Version: 1.3.3
|
8 |
+
Author URI: http://jameslao.com/
|
9 |
*/
|
10 |
|
11 |
// Displays widget on blag
|
55 |
echo '<li class="cat-posts-item-' . $post->ID . '"><a href="' . get_permalink($post) . '">' . $post->post_title . '</a>';
|
56 |
if( $excerpt ) {
|
57 |
echo '<br />';
|
58 |
+
if ($post->post_excerpt!=NULL)
|
59 |
+
echo $post->post_excerpt;
|
60 |
+
else
|
61 |
+
the_excerpt();
|
62 |
}
|
63 |
echo '</li>';
|
64 |
}
|
207 |
// This is important
|
208 |
add_action( 'widgets_init', 'jl_cat_posts_register' );
|
209 |
|
210 |
+
?>
|
readme.txt
CHANGED
@@ -3,8 +3,8 @@ Contributors: James Lao
|
|
3 |
Donate link: http://jameslao.com/
|
4 |
Tags: category, posts, widget
|
5 |
Requires at least: 2.5
|
6 |
-
Tested up to: 2.
|
7 |
-
Stable tag: 1.3.
|
8 |
|
9 |
Adds a widget that shows the most recent posts in a single category. You can specify how many posts to show and from which category as well as how many widgets to show.
|
10 |
|
@@ -27,4 +27,4 @@ Features:
|
|
27 |
1. Download the plugin.
|
28 |
2. Upload it to the plugins folder of your blog.
|
29 |
3. Goto the Plugins section of the WordPress admin and activate the plugin.
|
30 |
-
4. Goto the Widget tab of the Presentation section and configure the widget.
|
3 |
Donate link: http://jameslao.com/
|
4 |
Tags: category, posts, widget
|
5 |
Requires at least: 2.5
|
6 |
+
Tested up to: 2.7-beta3
|
7 |
+
Stable tag: 1.3.3
|
8 |
|
9 |
Adds a widget that shows the most recent posts in a single category. You can specify how many posts to show and from which category as well as how many widgets to show.
|
10 |
|
27 |
1. Download the plugin.
|
28 |
2. Upload it to the plugins folder of your blog.
|
29 |
3. Goto the Plugins section of the WordPress admin and activate the plugin.
|
30 |
+
4. Goto the Widget tab of the Presentation section and configure the widget.
|