wp_dropdown_categories()
will produce a select element with the default name and id of cat
. You can change these by passing different values for id
and cat
in the $args
array. The default value
it uses is the term_id. Depending on what you’re expected to use in the get_field()
function, you can also change that in the $args
array.
$args = array(
'taxonomy' => 'download_category',
'order' => 'ASC',
'value_field' => 'slug',
);
Then in the second part:
$cat = esc_attr( $_GET[ 'cat' ] );
$product_args = array(
'post_type' => 'download',
'posts_per_page' => $per_page,
'offset' => $offset,
'download_category' => $cat,
);
I’ve never combined ACF and EDD this way, so it might need some fiddling.
Related Posts:
- Getting custom taxonomy from custom post type
- Filter next_post_link() and previous_post_link() by meta_key?
- Automatically fill custom field value on post publish/update
- Make permalinks based on an ACF-field
- How to sort a table of custom posts by column containing custom field
- List events by month
- Use Custom Post Type as Custom Field
- Conditional two level dropdown filter for custom post type
- Dynamic dropdown custom post list based on dropdown selection
- Set default option in dropdown of WP_Query?
- Pull image from ACF field in a Custom Post Type
- Archive filter disappears on no results?
- Show ACF field from custom taxonomy and display on the single template
- WordPress custom post type archive with description
- wp_update_post based function works on existing posts, but not new posts
- How to Display ACF Relationship Custom Field as Link to Specific Custom Post?
- Show custom field from custom taxanomy term on custom post type
- How to replace custom post type slug with an ACF value?
- Link users to a custom post type
- How to display Custom Post Type Post based on Tag with Shortcode Parameter?
- Validate custom fields before save using WordPress Rest API
- How can I dynamically add a post to a custom post type which uses a custom field?
- Problem with WordPress query on page using custom fields
- Widget: Custom Post Type Post Listing Dropdown on Admin Side
- Custom Taxonomy terms aren’t getting referenced or saved in Quick Edit or Bulk Edit, only on Single product page?
- WP_Query to select custom post type with Advanced Custom Fields (ACF) date
- Multiple level category drop-down from the WordPress dashboard
- Troubles with acf/save_post and WP_Query
- Query custom post type with ACF Date
- custom post type WYSIWG removes paragraphs when displayed
- ACF From & To Date Validations
- Exclude objects from WordPress API based from ACF field using rest_prepare_{$post_type}
- CPT archive admin menu label
- Rewrite Rule for showing Parent/Child Relationship between Two Hierarchical Custom Post Types
- Order Custom Post Type by Custom Field Value
- Lists custom taxonomy terms that has specific custom field value assigned to the term (not post)
- How to update post meta on uploaded image from a custom form?
- Order post by date with ACF
- Adavnced custom fields relationship query plus query inside
- Recoverable Fatal Error – Object of class WP_Post could not be converted to string
- Querying & displaying custom post type into an existent page [closed]
- Custom post type showing same Post on all Pages
- Post loop count is not in order
- How to inherit field value from parent post into in child / sub post
- echo selected value from dropdown
- Unable to display selected post title in frontend from metabox wp_dropdown_pages()
- How to use single.php for creating, reading and editing Custom Posts with ACF
- posttype and custom fields on multisite
- Advanced custom fields Post Object image field not displaying in custom post type single.php
- Sum and count of custom field values
- How do I show a link or ‘Read More’ button on a custom field excerpt when it is less than the word limit
- Custom fields not showing in custom post type
- meta query not retrieving posts
- Add search to ‘Parent’ dropdown
- Display Taxonomy Term Children in a Drop Down without Submit Button
- Using WP meta query to show custom post types by a start and finish date
- Advanced custom field – posted fields from custom post type
- How to display author details in a custom post type in the wordpress backend?
- Show/hide posts and categories based on user meta
- ACF – Retrieve custom taxonomy from a relationship field
- How to set a ‘page’ as parent of a custom post type?
- Custom front-end form for adding post – Category problem
- Set up a WP Cron scheduled event to update calculated ACF field
- Show Post Revisions on front-end
- How to show Custom Post Type – Case Study using Shortcode & ACF
- Add custom post related by custom field to custom post
- Create loop from selected terms in ACF taxonomy field
- Sort custom posts by date and then by taxonomy
- Query posts by current ACF meta key value on single page as related posts
- Show custom post type event if current day using ACF
- Issue to display Permalink (ACF Relationships in Custom Post Type )
- Filter posts by their related field’s custom field
- If ACF Post Object post has custom taxonomy term…
- Changing default admin column sorting to an ACF Date Picker field
- Taxonomy shows up twice on Custom Post Type
- Permalink URL connection between two custom types
- Create 3 Levels of relations with WordPress
- Wrapping an unknown amount of posts inside separate HTML Containers during WP_Query loop
- Show specific posts with WP_Query using ACF Post object
- filter post by date selected in a dropdown in realtime
- Some permalinks on Apache/localhost development setup return 404’s when set to anything other than plain permalinks
- How to get a custom post type archive paged when using a custom field for post sorting?
- save_post affect creation and deletion
- Can’t pick up a field created with Advanced Custom Fields
- wp_dropdown_pages doesn’t allow me to select more than one custom post type
- How to query posts by meta keys AND under specific category?
- using ACF datepicker to filter posts on a page
- how to load custom single.php?
- Setting a custom $query->query_vars[‘meta_key’] breaks the WordPress menu
- Function that get ACF fields value before saving
- How to query the content of a specific custom post type?
- Custom Post-type not returning the right child_of
- Register a title automatically with a relationship field
- ACF – Query relationship without ID
- ACF Field to set Publish Date – Post Duplication upon Update
- Getting ACF relationship field information
- Why custom search engine only searches in post titles of custom posts?
- Post object GUID adding http:/
- Display custom post type attached media file sizes
- WordPress post objects in one parent post object