Displays most recent posts from a specific featured category or categories.
Plugin with multi-widget functionality that displays most recent posts from specific category or categories (set with user options). Also includes user options to display: Category Description; Author and meta details; comment totals; post categories; post tags; and either full post, excerpt, or your choice of the amount of words (or any combination). Please make sure to read the latest changelog for new and modified features and options.
* Copyright 2009-2016 Edward Caissie (email : [email protected])
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License version 2,
as published by the Free Software Foundation.
You may NOT assume that you can use any other version of the GPL.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
The license for this software can also likely be found here:
http://www.gnu.org/licenses/gpl-2.0.html
This section describes how to install the plugin and get it working.
bns-featured-category.php
to the /wp-content/plugins/
directory— or –
Read this article for further assistance: http://wpfirstaid.com/2009/12/plugin-installation/
Parameters are very similar to the plugin:
NB: Use the shortcode at your own risk!
You will need to use an FTP client to add the /bns-customs/
folder under the /wp-content/
folder, then place your bns-custom-style.css
file in the /bns-customs/
folder.
The /bns-customs/
folder will be used as an update safe location for all plugins I write.
As most of these plugins use the “BNS” designator, the folder name will make it easier to locate your customizations.
Yes, this plugin has been made for multi-widget compatibility. Each instance of the widget will display, if wanted, differently than every other instance of the widget.
The plugin uses several “common” WordPress functions that create standard class and id elements that can be styled in the style.css file
* the classes generated by the post_class() function; and, the id generated by “post-” appended to the_ID() function wrap the general post output
* the plugin class post-details
wraps the general meta details of the post, such as the Author, Categories, Tags, etc.
* the overall plugin may also be wrapped in a widget “container” class, or id, specific to the theme itself such as (but not limited to): widget, sidebar, left, right, etc.
As of version 1.9, you may create a custom stylesheet using the name bnsfc-custom-style.css
; and save it to the BNS Featured Category plugin folder.
Elements you add into this file will not be overwritten with future plugin updates. With the addition of the display Category Description option an additional class was written into the plugin.
To style the category description displayed add the class ‘bnsfc-cat-desc’ to your bnsfc-custom-style.css file then use your choice of properties to style the text, for example:
.bnsfc-cat-desc {font-style: italic;}
The following CSS elements are generated by the plugin code:
Additional style elements may be available but are most likely created through WordPress core functionality, the current active Theme, or another active plugin.
As of version 1.6.2 the Total Posts to Display is independent of the “posts per page” setting as set under Settings | Reading.
BNS_Feature_Category_Widget
to BNS_Featured_Category
BNS_Featured_Category::custom_excerpt
with wp_trim_words
textdomain
from bns-fc
to bns-featured-category
readme.txt
bnsfc-container
wrapper CSS elementbnsfc-widget-title
classbnsfc_no_posts_message
hook to no posts messageplugin_data
methodreadme.txt
documentationbnsfc_query
allowing the query arguments to be over-writtenbnsfc_output
allowing the entire output to be over-writtenbnsfc_link
to allow the infinity symbol to be more easily changedshortcode_atts
for automatic filter creationquery_posts
to WP_Query
get_the_excerpt
to be used as the basis of the custom excerpt stringBNS_Options_Scripts_and_Styles
*-toggle
variables for collapse effectcurrent_theme_supports
check for post-thumbnails
; no support = no thumbnail optionswp_enqueue_scripts
parametersbnsfc-style.css
for plugin specific elementswp_link_pages
after the_content
bnsfc_first_words
to bnsfc_custom_excerpt
(refactored documentation)bns-cat-class-
to bnsfc-cat-class-
CSS prefix for category choices for consistencyload_bnsfc_widget()
, bnsfc_custom_excerpt()
<div style="overflow-x: auto">
wrapper to allow for images wider than the widget area