=== Blog Filter Post Filtering  ===
Contributors: awordpresslife, razipathhan, hanif0991, muhammadshahid, fkfaisalkhan007, sharikkhan007, zishlife, FARAZFRANK
Donate link: https://paypal.me/awplife
Tags: blog filter, post grid, blog layout, category filter, tag filter
Requires at least: 5.0
Tested up to: 6.9
Requires PHP: 7.0
Stable tag: 1.7.8
License: GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html

Blog Filter helps users display posts in filterable grid and masonry layouts. Organize content by categories or tags with customizable designs.

== Description ==

**Blog Filter** is a WordPress plugin designed to help website owners display their blog posts in organized, filterable layouts. Whether you run a personal blog, news site, or content-heavy portal, this plugin provides an intuitive way for visitors to browse and discover posts based on categories or tags.

The plugin automatically fetches your existing WordPress posts and displays them in a grid or masonry layout. Visitors can click on filter buttons to instantly see posts from specific categories or tags, making content discovery much easier on sites with large archives.

[youtube https://www.youtube.com/watch?v=7Ue3eIM3nu4]

**Upgrade To Premium -  <a href="https://awplife.com/wordpress-plugins/blog-filter-wordpress-plugin/">Blog Filter Plugin</a>**

**Premium <a href="https://awplife.com/demo/blog-filter-premium/">Blog Filter Plugin Demo</a>**

= What Does Blog Filter Do? =

At its core, Blog Filter takes your WordPress posts and presents them in a visually organized manner. Instead of showing posts in a traditional chronological list, you can display them in:

* **Grid Layouts** - Posts arranged in neat rows and columns
* **Masonry Layouts** - Pinterest-style arrangement that optimizes space by eliminating gaps between posts of different heights

The filtering functionality lets visitors click on category or tag buttons to view only the posts that match their interests. This happens dynamically on the page without requiring a reload.

= Who Can Benefit From This Plugin? =

**Content Publishers**: If your site has hundreds of articles across multiple topics, filtering helps readers find relevant content quickly.

**News Websites**: Organize stories by categories like sports, technology, entertainment, and let users toggle between sections.

**Educational Blogs**: Students and researchers can filter posts by subject matter or topic tags.

**Portfolio Blogs**: Showcase written work or case studies with easy category-based navigation.

**Magazine-Style Sites**: Present content in a visually appealing grid that resembles magazine layouts.

= Quick Setup Guide =

1. Install and activate the plugin through your WordPress dashboard
2. Navigate to "Plugins Menu > Blog Filter Settings"
3. Configure the appearance and filtering options
4. Copy the generated shortcode
5. Paste the shortcode into any page, post, or widget area

That's it. The plugin handles the rest automatically.

= Available Languages =

Blog Filter supports multiple languages out of the box:

* Arabic (ar)
* Chinese (zh_CN)
* Dutch (nl_NL)
* Finnish (fi_FI)
* French (fr_FR)
* German (de_DE)
* Hebrew (he_IL)
* Hindi (hi_IN)
* Hungarian (hu_HU)
* Indonesian (id_ID)
* Italian (it_IT)
* Japanese (ja_JP)
* Polish (pl_PL)
* Portuguese (pt_PT)
* Russian (ru_RU)
* Spanish (es_ES)

You can also translate the plugin into your native language using standard WordPress translation methods.

== Blog Filter Features ==

= Automatic Post Detection =
The plugin automatically pulls in your existing WordPress posts. There's no manual entry required - just install, configure your display preferences, and your posts appear in the filtered layout.

= Category and Tag Filtering =
Choose whether to filter posts by categories, tags, or both. Filter buttons appear above your post grid, allowing visitors to narrow down content with a single click.

= Responsive Grid Layout =
Posts display in a grid format that adapts to screen sizes. Whether someone visits on a desktop monitor, tablet, or smartphone, the layout adjusts accordingly.

= Masonry Arrangement =
Enable masonry layout to create that Pinterest-style look where posts of varying heights fit together without awkward gaps. This works particularly well when your posts have featured images of different dimensions.

= Image Quality Control =
Select the image resolution for displayed thumbnails. You can opt for high-resolution images on design-focused sites, or choose smaller sizes for faster page loads.

= Multi-Color Filter Buttons =
Apply different colors to your filter buttons to match your site's design or to help visitors visually distinguish between categories.

= Post Titles and Details =
Show or hide post titles, dates, authors, and other metadata. Control what information appears beneath each post thumbnail.

= Automatic Post Links =
Each post in the grid links directly to its full single post page. No additional configuration needed.

= Shortcode-Based Placement =
Use the generated shortcode to place your filtered post grid anywhere on your site - pages, posts, sidebar widgets, or page builder sections.

= Load More Functionality =
Instead of pagination, you can enable a "Load More" button that fetches additional posts without page reloads.

= Custom Post Type Support =
Display posts from custom post types, not just standard WordPress posts.

== Premium Version Features ==

The premium version of Blog Filter includes additional capabilities:

= BLOG FILTER PREMIUM FEATURES WITH DEMO =

* [Blog Filter Premium Layout 1](https://awplife.com/demo/blog-filter-premium/template-1/ "Blog Filter Premium (Blog Post Grid Layout 1)")
* [Blog Filter Premium Layout 2](https://awplife.com/demo/blog-filter-premium/template-2/ "Blog Filter Premium (Blog Post Grid Layout 2)")
* [Blog Filter Premium Layout 3](https://awplife.com/demo/blog-filter-premium/template-3/ "Blog Filter Premium (Blog Post Grid Layout 3)")
* [Blog Filter Premium Multiple Column Layout](https://awplife.com/demo/blog-filter-premium/column-layout/ "Blog Filter Premium (Blog Post Grid Layout with filters)")
* [Blog Filter Premium Without Image](https://awplife.com/demo/blog-filter-premium/blog-filter-without-image/ "Blog Filter Premium (Blog Post without Image Layout with filters)")
* [Blog Filter Premium Without Filters](https://awplife.com/demo/blog-filter-premium/blog-without-filter/ "Blog Filter Premium (Blog Post without Filters Layout)")
* [Blog Filter Premium With Hover Effects](https://awplife.com/demo/blog-filter-premium/hover-effect-1/ "Blog Filter Premium (Blog Post Multi Hover Effects)")
* [Blog Filter Premium With Lightbox](https://awplife.com/demo/blog-filter-premium/ "Blog Filter Premium (Blog Post Image With Lightbox)")
* [Blog Filter Premium With Single Post Link On Image](https://awplife.com/demo/blog-filter-premium/ "Blog Filter Premium (Blog Post Image With Single Post Link On Image)")
* [Blog Filter Premium With Second Variation for Title, Date & Author](https://awplife.com/demo/blog-filter-premium/second-veriation/ "Blog Filter Premium (Blog Post Image With Second Variation for Title, Date & Author)")

= Premium Features Include =

* Multiple pre-designed templates
* Up to 4-column layouts
* Five hover effects for post thumbnails
* Lightbox popup for featured images
* Unlimited filter colors
* Custom CSS option for advanced styling
* Widget support for sidebar placement
* Additional post metadata display options
* Bootstrap-based framework
* Priority support

== Understanding Masonry Layouts ==

Masonry layout arranges elements in a grid where items are positioned to fill vertical space efficiently. Unlike traditional grids where each row has the same height, masonry allows items of different sizes to stack closely together.

This layout style became popular through sites like Pinterest and works well for:

* Posts with varied featured image dimensions
* Content archives with mixed media types
* Visual portfolios and galleries
* Magazine-style homepage designs

Blog Filter handles masonry calculations automatically. You enable the option, and the plugin takes care of positioning each post to minimize empty space.

== Lightbox Functionality ==

The premium version includes Swipebox lightbox integration, which displays featured images in an overlay popup. Key lightbox features:

* Swipe gestures for mobile navigation
* Keyboard navigation on desktop
* CSS transitions with jQuery fallback
* Retina-ready UI icons
* Browser compatibility: Chrome, Safari, Firefox, Opera, IE9+, iOS 4+, Android, Windows Phone

== Screenshots ==

1. Blog Filter Gallery with category filters
2. Blog Filter Gallery without featured images
3. Blog Filter Layout with post filtering
4. Blog Filter Gallery displaying posts without images
5. Settings page interface

== Installation ==

= From WordPress Dashboard =
1. Go to Plugins > Add New
2. Search for "Blog Filter"
3. Click Install Now, then Activate
4. Find Blog Filter Settings in your admin menu

= Manual Installation =
1. Download the plugin zip file
2. Extract and upload the `blog-filter` folder to `/wp-content/plugins/`
3. Activate through the Plugins menu
4. Configure settings and generate your shortcode

== Frequently Asked Questions ==

= How do I display the filtered posts on my site? =

After configuring your settings, copy the shortcode displayed in the Blog Filter admin panel. Paste this shortcode into any page, post, or text widget where you want the filtered post grid to appear.

= Can I filter by both categories and tags? =

Yes. In the settings, you choose whether to use post categories, post tags, or both as your filter criteria.

= Does the plugin work with custom post types? =

The premium version includes custom post type support. You can display and filter content from any registered post type.

= Will this slow down my website? =

The plugin is designed with performance in mind. You can also select lower image resolutions to reduce page load times on image-heavy layouts.

= Is the layout mobile-friendly? =

Yes. The grid layout is fully responsive and adjusts to fit screens of all sizes, from large desktop monitors to mobile phones.

= Can I customize the appearance? =

The settings panel includes options for colors, visibility toggles, and layout preferences. The premium version adds custom CSS support for more advanced styling.

= What if I need help? =

Post your questions on the WordPress plugin support forum:
https://wordpress.org/support/plugin/blog-filter/

== Recommended Plugins ==

Other plugins from the same development team:

* [Portfolio Filter Gallery](https://wordpress.org/plugins/portfolio-filter-gallery/ "Portfolio Filter Gallery") - Create filterable image galleries for portfolios, photography, and artwork.

* [Instagram Type Gallery](https://wordpress.org/plugins/insta-type-gallery/ "Instagram Type Gallery") - Display images in Instagram-inspired grid layouts.

* [Grid Gallery](https://wordpress.org/plugins/new-grid-gallery/ "Grid Gallery Plugin") - Simple grid layout for image galleries in posts, pages, and widgets.

* [Image Gallery](https://wordpress.org/plugins/new-image-gallery/ "Image Gallery Plugin") - Lightbox-enabled gallery for displaying images.

* [Photo Gallery](https://wordpress.org/plugins/new-photo-gallery/ "Photo Gallery Plugin") - Versatile gallery supporting photos, videos, links, and maps.

* [Responsive Slider Gallery](https://wordpress.org/plugins/responsive-slider-gallery/ "Slider Plugin") - Create responsive image sliders with shortcode placement.

* [Video Gallery](https://wordpress.org/plugins/new-video-gallery/ "Video Gallery Plugin") - Display video content in organized gallery layouts.

* [Contact Form Widget](https://wordpress.org/plugins/new-contact-form-widget/ "Contact Form Plugin") - Add contact forms via shortcodes and widgets.

* [Social Media Widget](https://wordpress.org/plugins/new-social-media-widget/ "Social Media Widget") - Display social media profile links in your sidebar.

* [Slider Responsive Slideshow](https://wordpress.org/plugins/slider-responsive-slideshow/ "Responsive Slider Plugin") - Lightweight responsive slider for WordPress.

* [Facebook Like Box](https://wordpress.org/plugins/facebook-likebox-widget-and-shortcode/ "Facebook Likebox Plugin") - Embed Facebook page like boxes on your site.

== Changelog ==

= 1.7.8 =
* Fixed: AJAX "Load More" functionality by ensuring absolute paths for template inclusion.
* Fixed: Posts-per-page query logic in AJAX handlers to use unified settings.
* Fixed: AJAX Term count logic for accurate post distribution across categories.
* Improved: JavaScript post insertion for Filterizr grid to handle multiple items and prevent layout issues.
* Fixed: Constant definition error in main plugin file.

= 1.7.7 =
* Plugin Check Compliance: Replaced all _e() with esc_html_e() across settings page
* Plugin Check Compliance: Added version parameters to all wp_enqueue_style/script calls
* Plugin Check Compliance: Removed offloaded CDN Tailwind script from settings page
* Security: Escaped all PHP output in inline JavaScript with esc_js()
* Security: Escaped admin_url() with esc_url() and wp_create_nonce() with esc_attr()
* Security: Replaced json_encode() with wp_json_encode() for safe JSON output
* Security: Escaped $disabled and $is_selected variables in printf() with esc_attr()
* Security: Wrapped wp_strip_all_tags() output in esc_html() for custom CSS
* Security: Escaped get_day_link() output with esc_url() in templates
* Fixed: CSS selector spacing issues in blog-filter-output-css.php

= 1.7.6 =
* Added option to disable Bootstrap CSS loading
* Added option to disable Bootstrap JS loading
* Prevents conflicts when theme already includes Bootstrap

= 1.7.5 =
* Default variables fixed.

= 1.7.4 =
* Security: Fixed Stored Cross-Site Scripting (XSS) vulnerability
* Security: Added proper output escaping for all shortcode attributes
* Security: Sanitized custom CSS output with wp_strip_all_tags()
* Security: Fixed unsafe innerHTML assignments in JavaScript with textContent
* Security: Sanitized AJAX targetFilter parameter
* Security: Fixed $_GET['filter'] handling with proper sanitization
* Security: Added sanitization for critical bfg_query_vars fields
* Improved: Added esc_attr() and esc_html() escaping throughout templates
* Improved: Better input validation for AJAX handlers

= 1.7.3 =
* Tested compatibility with WordPress 6.9

= 1.7.2 =
* Removed automatic redirect to settings page after activation
* Tested compatibility with WordPress 6.8.3

= 1.7.1 =
* Fixed load more button color styling issue
* Tested compatibility with WordPress 6.8.2

= 1.7.0 =
* Redesigned settings page interface
* Added custom post type support for pages
* Introduced load more post feature
* Added multiple new post display options

= 1.6.5 =
* Fixed pagination issue

= 1.6.4 =
* Resolved text domain error

= 1.6.3 =
* Tested compatibility with WordPress 6.8.1
* Fixed issue with extra page URLs generating when pagination is disabled

= 1.6.2 =
* Tested compatibility with WordPress 6.8
* Regular maintenance and updates

= 1.6.1 =
* Added Hebrew language translation

= 1.6.0 =
* Tested compatibility with WordPress 6.7.1
* Regular maintenance and updates

== Upgrade Notice ==

= 1.7.7 =
Plugin Check compliance update. Fixes security escaping, removes CDN dependency, and ensures all outputs are properly escaped. All users should update.