Support

Search results for ""

Sorry, no results found. Perhaps you would like to search the documentation?
All Topics
Michael Barton

Woocommerce + ACF – Ability to change the link

Within Woo-commerce’s products display list; when an ACF custom field is added, the link can be changed in the settings to edit or view. What about having the link click to filter by that ACF field? Is there a way to change the link via filter hook?

2 years, 10 months ago
Stefan van den Dungen Gronovius
Developer

Are you talking about the ACF Relation column (or any ACF field that is related to posts)?
You could disable the link in the settings and wrap the value yourself with the following hook:
https://github.com/codepress/admin-columns-hooks/blob/master/ac-column-value.php

If the column has multiple posts, you can call the $column->get_raw_value( $id ) method to retrieve the base ID’s and generate the link plus label (Post property) yourself.

2 years, 10 months ago

You must be logged in to reply to this topic.