Category: ACF

With 196 articles also related to:

Aleš Sýkora wrote:

ACF Gallery in Bricks Loop

February 26, 2024 in ACF, Bricks Builder, Custom Code, Plugins, WordPress

If you want to build your own gallery layout and you want to be completely free of Bricks Gallery block, then you may need to use custom query.

Continue reading

Aleš Sýkora wrote:

Bricks: Get ACF Radio field Value and Label

August 28, 2023 in ACF, Bricks Builder, Plugins, WordPress

This tutorial is made for Brics Builder users who you use ACF Radio field set to return Array and wants to get the Value or Name of the radio selected. Make sure your ACF radio field is set to return Both (Array) and your options contains both of them like this: After the Bricks Builder…

Continue reading

Aleš Sýkora wrote:

How to Retrieve ACF Field from a Group field within an Option Page

November 28, 2023 in ACF, Custom Code, Plugins, WordPress

If you want to use ACF fields data from option page – it’s easy. You can just use get_field(‘field_slug’,’option’) unless you wrap the field in the group field. Let’s take a look how to get the field data. Understanding the Structure of Advanced Custom Fields Before we dive into the specifics, let’s take a moment…

Continue reading

Aleš Sýkora wrote:

Swiper.js ACF Gallery slider

November 28, 2023 in ACF, Custom Code, Oxygen Builder, Plugins, WordPress

Create Swiper image slider with ACF gallery field data.

Continue reading

Aleš Sýkora wrote:

ACF flexible content: Oxygen builder examples

January 6, 2023 in ACF, Custom Code, Oxygen Builder, Plugins, WordPress

Here are some code examples really useful when using ACF flexible content with Oxygen. The main workflow of using ACF flexible content with Oxygen is simple. Here are the main rules: How to work with ACF flexible content and Oxygen? There is a process: Tips for ACF Flexible content and Oxygen modules Oxygen Image module…

Continue reading

Aleš Sýkora wrote:

ACF nested repeaters as document library

November 28, 2023 in ACF, Oxygen Builder, Plugins, WordPress

If you want to prepare a Documents page for your website, you may consider creating it with ACF Pro repeaters. I Use these three ACF repeaters: Main repeater (slug: docs-group) = Document category name (for example – manuals) with classic editor to add some description to categorySecondary repeater (slug: documents) = Document Subcategory name (for…

Continue reading

Aleš Sýkora wrote:

ACF Local JSON with Oxygen Builder

November 28, 2023 in ACF, Custom Code, Oxygen Builder, Plugins, WordPress

Would you like to speed up your page? If you use Advanced Custom Fields plguin, you may try the local JSON. Local JSON is a new feature added in version 5 which saves field group and field settings as .json files within your theme. The idea is similar to caching, and both dramatically speeds up…

Continue reading

Aleš Sýkora wrote:

Change youtube to youtube-nocookie with ACF embed field

November 28, 2023 in ACF, Custom Code, Plugins, WordPress

With Cookie and GDPR laws, you should display the YouTube and other embeds only after user consent to marketing cookies. There is a way to avoid this but still send user IP address to YouTube and store one cookie instead of multiple ones. The way is a change of YouTube Embed URL to “youtube-nocookie.com” .…

Continue reading

Aleš Sýkora wrote:

Use first ACF Gallery image as Featured image of Custom post type single

January 9, 2024 in ACF, Custom Code, Plugins, WordPress

How do I set the first gallery image from a custom post type gallery field as the featured image? Found this here: Use first image from gallery of custom post type to set featured image – ACF Support (advancedcustomfields.com) It use ACF | acf/save_post (advancedcustomfields.com) filter to apply. Regenerate all posts to set the featured…

Continue reading

Aleš Sýkora wrote:

Get ACF taxonomy field for current post in Query

April 5, 2022 in ACF, Oxygen Builder, Plugins, WordPress

For a situation where you need to display ACF taxonomy field for current terms assigned to the post in the WP Query, you may need the code below. Why to use ACF taxonomy field? It’s easy. I am using this for SEO purposes. How? I am creating website for language school. My taxonomy is called…

Continue reading