Home » Blog » Introducing the Conductor REST API, AJAX Widgets, front-end Filtering, and more!
Blog, Changelog, Conductor

We’re happy to announce that the newest version of Conductor is here! Today, we’re introducing the Conductor REST API, AJAX in Conductor Widgets, and a front-end Filtering add-on. We are also releasing a bunch of other enhancements and bug fixes to most of our other add-ons.

The Conductor REST API

Version 1.5.0 of Conductor ships with a REST API! The Conductor REST API provides API endpoints for Conductor which allow developers to interact with sites remotely (i.e. via AJAX requests).

We have some initial documentation to help explain how the Conductor REST API works.

We’ve also introduced a new Conductor option to enable or disable the Conductor REST API entirely. You can find this setting in Conductor > Options in the WordPress admin.

Conductor Widget AJAX

Conductor Widgets now support AJAX requests for querying content. This means that, when navigating from page to page in a Conductor Widget for instance, the widget can make an AJAX request to the Conductor REST API and load the content within the widget container instead of reloading the entire page. Anyone who is familiar with the Customizer will likely recognize this behavior.

We’ve introduced a new setting called “Enable in REST API” to Conductor Widgets. This setting allows individual widgets to either be enabled or disabled in the Conductor REST API. If this setting is unchecked, that Conductor Widget will be disabled in the Conductor REST API. This setting is located in the “Advanced Settings” section of Conductor Widgets. Use this setting for more granular control of your Conductor Widgets.

Conductor Widget Legacy Displays Deprecated

The Small, Medium, and Large Conductor Widget displays are now deprecated. Previously we had mentioned that these displays were considered legacy as of version 1.3.0.

Note: The Column display was labeled as “Custom” in Conductor version 1.3.0.

We’ve included backwards compatibility to ensure that legacy displays will transition to the Column display gracefully if they are still in use. Here’s how that logic works:

  • Small: The Columns display will be utilized on the front-end with the number of columns set to 4.
  • Medium: The Columns display will be utilized on the front-end with the number of columns set to 2.
  • Large: The Columns display will be utilized on the front-end with the number of columns set to 1.

When a Conductor Widget is saved/updated, the Column display will be set as the new display (unless another display is selected) if that widget previously had a legacy display selected.

Conductor Filtering

Perhaps the biggest (and best) part of this round of updates is our newest add-on, Conductor Filtering! This brand new add-on allows users to filter content displayed in your Conductor Widgets to narrow it down to their desired results.

The Conductor Filtering add-on currently supports filtering for registered taxonomies. Any content type, when selected for use in a Conductor Widget, that has a registered taxonomy attached to it can have filtering enabled.

When filtering is enabled on a Conductor Widget that does not have any pagination, jQuery Isotope is used for smooth on-page filtering. For Conductor Widgets with pagination, the Conductor REST API is used via AJAX requests.

This is a great addition for news sites, portfolios, or even your own personal blog! We can’t wait to see what you’ll build with it!

Other Notable Updates

We also have some other notable updates that we’d like to highlight.

In Conductor Widgets, we’ve added HTML wrapper elements to the different sections (e.g. content and pagination). These wrapper elements were added as a result of the new Conductor REST API.

We also fixed a bug where global $post data was not reset in some cases after a Conductor Widget was displayed.

Custom Fields Add-On

Our Custom Fields add-on received some updates as well. It’s now easier to add custom fields as output elements to your Conductor Widgets. You will no longer have to search for custom fields (though you still can). The list of available custom fields is displayed when the custom fields input element is focused.

Display Pack Add-On

We’ve improved our Enhanced Table display to ensure the maximum number of posts was honored in the page length menu. Previously the maximum number of posts value was either not added to the page length menu or values larger than the maximum number of posts value

We also fixed a possible fatal PHP error that occurred due to Yoast SEO removing all widget_init hooks on the sitemap endpoint.

Gravity Forms Add-On

Our Gravity Forms add-on will now utilize the current date format stored in settings when displaying date fields.

Ninja Forms Add-On

Our Ninja Forms add-on will also now utilize the current date format stored in settings when displaying date fields.

We also fixed a possible fatal PHP error due to missing parameter in NF_Database_Models_Submission::get_sub_date() when the sub_date custom field was used as an output element in Conductor Widgets.

Query Builder Add-On

In the Query Builder Add-On, we’ve improved usability in the shortcode query builder module. We also added “Edit Query” helper buttons for logged in users on the front-end to easily navigate to the edit query page. The “Edit Query” buttons will appear after the query title as well as after the query.

Along with the above improvements, we fixed a bug where the FROM query argument action buttons were not visible in some cases which, in-turn, did not allow other query arguments to be added to a query.

We also fixed a few possible PHP notices as well as a possible fatal PHP error that occurred due to Yoast SEO removing all widget_init hooks on the sitemap endpoint.

User Profiles Add-On

We fixed a bug in our User Profiles add-on where the User Profiles custom fields were not displayed in the Custom Fields add-on list when a User Profiles post type was selected.

WooCommerce Add-On

We’ve added WooCommerce 3.0+ support to our WooCommerce add-on.

We’ve also added logic to utilize the woocommerce_template_single_excerpt() function when displaying the excerpt (WooCommerce calls this the Short Description).

Along with that, we have added support for the following WooCommerce fields:

  • Downloadable (Flag; Displayed as either “Yes” or “No”)
  • Downloads (a list of downloads for a WooCommerce product)
  • Featured (Flag; Displayed as either “Yes” or “No”)
  • Product Type
  • Rating
  • Sale Dates
  • SKU
  • Sold Individually (Flag; Displayed as either “Yes” or “No”)
  • Stock Status
  • Virtual (Flag; Displayed as either “Yes” or “No”)
  • If taxes enabled in WooCommerce:
    • Tax Class
    • Tax Status

Official Changelogs

Conductor

  • Introduced the Conductor REST API
  • Added option to enable/disable the Conductor REST API
  • Introduced AJAX logic to Conductor Widgets (allow widgets to load results via AJAX instead of a page refresh)
  • Added various HTML wrapper elements to “wrap” (contain) various pieces of content within a Conductor Widget
  • Deprecated legacy Conductor Widget displays
  • Introduce conductor_widget_enable_legacy_displays filter to allow legacy Conductor Widget displays to be enabled
  • Adjusted logic to render widget options to ensure the correct options were displayed based on the feature type and content type fields
  • Adjusted logic to set the Conductor Widget content type to ensure it always occurred after other rendering logic
  • Added logic to store the current query arguments and query on the Conductor_Widget_Default_Query PHP class
  • Introduced Conductor_Widget_Query::get_query_args() to get the current query arguments
  • Added logic to Conductor_Widget_Query to allow instances to skip adding the display content hooks
  • Adjusted default category Conductor Widget setting to zero (was previously false)
  • Fixed a bug where the global $post data was not reset in some cases after Conductor Widget content was displayed
  • Added “data-default-value” and “data-default” attributes to all Conductor Widget settings
  • Added $widget, $query, $this (Conductor_Widget_Default_Query instance) parameters to conductor_widget_featured_image_size filter
  • Added “inline-block” CSS styles to allow for inline-block elements in Conductor Widget settings
  • Adjusted add-ons logic to allow for a “check requirements” function name to be passed along with add-on data (default to plugins_loaded for the requirements check if this function name is not specified)
  • Adjusted logic to sanitize CSS classes
  • Removed various Note backwards compatibility that was no longer necessary

Custom Fields Add-On

  • Added logic to automatically open jQuery AutoComplete results when the custom fields input in Conductor Widgets is focused
  • Added logic to keep the jQuery AutoComplete results open after a custom field was selected
  • Added “conductor-widget-setting” CSS class to all Conductor Widget settings
  • Added default value data attribute to the custom fields input setting
  • Added skip query builder preview data attribute to the custom fields input setting

Display Pack Add-On

  • Fixed a display bug where the List display items were too small
  • Fixed a bug where the maximum number of posts was not honored in the Enhanced Table Display as one of the length menu items
  • Fixed a bug where values greater than the maximum number of posts were displayed in the Enhanced Table Display length menu items
  • Fixed a possible fatal PHP error due to the removal of all widgets by Yoast SEO
  • Removed clearing element before pagination for Grid display
  • Adjusted logic to determine CSS selector for Grid display (use widget ID if available)
  • Transitioned conductor_widget_title_after to conductor_widget_display_content_before for List display
  • Transitioned conductor_widget_pagination_before to conductor_widget_display_content_after for List display
  • Transitioned conductor_widget_title_after to conductor_widget_display_content_before for Table display
  • Transitioned conductor_widget_pagination_before to conductor_widget_display_content_after for Table display
  • Added default data attribute to the Display Table Headings, Display Table Footer, and Enhanced Table Display widget settings
  • Added “conductor-widget-setting” CSS class to all Conductor Widget settings
  • Added logic for the Conductor Filtering add-on (add Table display as unsupported)

Genesis Add-On

  • Fixed a bug where the plugin would not be de-activated when the required assets did not exist

Gravity Forms Add-On

  • Added logic to utilize the current date format stored in settings when displaying date fields
  • Fixed a bug where the Query Builder mode button was not disabled upon initialization if the Gravity Forms post type was selected
  • Fixed a bug where the “one” feature type select option could sometimes become enabled when it shouldn’t have
  • Added default value data attribute to the select Gravity Form setting
  • Added filters/logic in Conductor_Widget_Gravity_Forms_query::get_pagination_links() to allow Conductor to determine the correct paginate_links() arguments

Ninja Forms Add-On

  • Added logic to utilize the current date format stored in settings when displaying date fields
  • Fixed a bug where the Query Builder mode button was not disabled upon initialization if a Ninja Forms post type was selected
  • Added “conductor-widget-setting” CSS class to all Conductor Widget settings
  • Fixed a possible fatal PHP error due to missing parameter in NF_Database_Models_Submission::get_sub_date() when the sub_date custom field was used as an output element in Conductor Widgets
  • Fixed a bug where the “one” feature type select option could sometimes become enabled when it shouldn’t have

Query Builder Add-On

  • Adjusted logic to reset query builder settings to default values (use the “data-default-value” and “data-default” HTML attribute values instead of Conductor Widget defaults)
  • Fixed a bug where FROM query argument action buttons were hidden in the shortcode query builder in some cases
  • Fixed possible PHP notices that occurred when clause group data was expected to be an array but it was actually a string
  • Fixed a possible fatal PHP error due to the removal of all widgets by Yoast SEO
  • Adjusted logic to display “Edit Query” buttons for query builder front-end displays
  • Added logic to interact with the Conductor REST API (adjust query arguments, widget IDs, etc…)
  • Adjusted logic to determine if meta in memory (browser session) is empty
  • Added logic to preview the current query on the “keyup” event on query builder input elements
  • Added logic to utilize the “conductor-query-builder-skip-preview” attribute when attempting to preview a query
  • Added logic to skip previewing a query if the shortcode query builder was active
  • Adjusted _.debounce() timeout for previewing queries (changed from 300ms to 400ms)
  • Added logic to abort the current query builder preview AJAX request when attempting a new preview of a query
  • Added logic to remove the clause action buttons view from memory if it existed when removing the clause group view
  • Added conductor_query_builder_save_post_before and conductor_query_builder_save_post_after actions
  • Added conductor_query_builder_preview_query_before and conductor_query_builder_preview_query_after actions
  • Added logic to determine the maximum number of pages (for pagination) on query builder queries
  • Adjusted logic to convert simple query builder data to a single array to account for multidimensional array settings
  • Adjusted Beaver Builder logic to account for Beaver Builder 2.0+
  • Adjusted query builder “copy to clipboard” tooltip CSS

Slider Add-On

  • Moved the Conductor Query Builder add-on logic to its own class
  • Added logic for the Conductor Filtering add-on (add all slider display types as unsupported)
  • Added logic to reset (turn off) the AJAX enabled Conductor Widget setting if a slider display was selected

User Profiles Add-On

  • Fixed a bug where the Query Builder mode button was not disabled upon initialization if a User Profiles post type was selected
  • Fixed a bug where the User Profiles custom fields were not displayed when a User Profiles post type was selected
  • Added “conductor-widget-setting” CSS class to all Conductor Widget settings
  • Added filters/logic in Conductor_Widget_User_Profiles_query::get_pagination_links() to allow Conductor to determine the correct paginate_links() arguments

WooCommerce Add-On

  • Added WooCommerce 3.0+ support
  • Added various WooCommerce custom fields:
    • Downloadable (Flag; Displayed as either “Yes” or “No”)
    • Downloads (a list of downloads for a WooCommerce product)
    • Featured (Flag; Displayed as either “Yes” or “No”)
    • Product Type
    • Rating
    • Sale Dates
    • SKU
    • Sold Individually (Flag; Displayed as either “Yes” or “No”)
    • Stock Status
    • Virtual (Flag; Displayed as either “Yes” or “No”)
    • If taxes enabled in WooCommerce:
      • Tax Class
      • Tax Status
  • Added logic to utilize woocommerce_template_single_excerpt() function for the excerpt (WooCommerce Short Description); Thanks Matthew Bieschke
  • Added PHP visibility declarations to various PHP class functions
  • Adjusted text domain
  • Added logic to load plugin text domain via load_plugin_textdomain()
  • Introduce POT file

Having Issues After Updating?

We have tested all of these updates extensively across many versions and variations of WordPress. If you encounter any unexpected issues after upgrading, please let us know by submitting a support ticket.

 

Conduct your content!

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.