WP Manifestindependent plugin directory
manifest / content / custom-filter

Custom Filters

A Plugin For Custom Filters In Wordpress.

★ 9stars

Install

Download source zip No release zip yet

This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/hassan7303/custom-filter/archive/refs/heads/master.zip
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

LinkedIn Telegram Instagram GitHub Email

Custom Filters Plugin Documentation

Plugin Information

  • Plugin Name: Custom Filters
  • Description: A Plugin For Custom Filters In WordPress.
  • Version: 1.0.0
  • Author: Hassan Ali Askari
  • Author URI: Telegram
  • Plugin URI: GitHub
  • License: MIT
  • License URI: MIT License
  • Email: hassanali7303@gmail.com
  • Domain Path: Domain

Installation

  1. Download the plugin.
  2. Upload the plugin folder to the /wp-content/plugins/ directory.
  3. Activate the plugin through the 'Plugins' menu in WordPress.

Usage

Shortcode

To display the custom filters in your posts or pages, use the following shortcode:

[custom_filters]

Filter Structure And Features

This plugin creates a tabbed filter system for car products in WooCommerce. It includes:

  • Tabbed Interface: Filter products based on car types (Light Vehicles, Heavy Vehicles, API/SAE, Industrial).
  • Brand Selection: Choose brands based on car types.
  • Category Filtering: Filter products by category.
  • AJAX Search: Filter results are loaded without page refresh using AJAX.

Tabs

  1. Light Vehicles (خودروهای سبک):

    • Filters include Brand and Car.
  2. Heavy Vehicles (خودروهای سنگین):

    • Filters include Brand and Car.
  3. API / SAE:

    • Select different levels of API or SAE.
  4. Industrial (صنعتی):

    • Redirects to a product category page with industrial products.

Filters and Taxonomies

This plugin uses WooCommerce product taxonomies for filtering:

  • pa_brand: Brand taxonomy for cars.
  • pa_car: Car taxonomy.
  • product_cat: Product categories.

Example Code Snippets

To fetch terms for the filter dropdowns:


$brand_terms = get_terms(array(
    'taxonomy' => 'pa_brand',
    'hide_empty' => false,
));