Developing with Advanced Custom Fields

At SplitMango we use a powerful tool created for WordPress developers that makes life for our clients a lot more organized and, in turn, stress free. If you haven’t heard of Advanced Custom Fields (ACF) don’t worry we’re here to tell you all about it.

What is ACF?
ACF is a well documented, tested and popular tool which complements WordPress’ custom fields and allows the user to take full control of them. ACF has a full library of functions that load and display custom field data. Keep in mind you will need to understand PHP code before you use ACF.

Why we use ACF.
SplitMango loves using ACF. It’s a fantastic way to organize the edit screens in the backend of WordPress, which means an easier and stress free experience for our clients. Using ACF we are able to repeat similar types of content and create flexible containers for clients to change as they wish without breaking the design. Once a developer has gotten comfortable with the ACF documentation they’re able to build powerful templates quickly.

Tips on how we use ACF.
When you’re new to ACF there’s a lot of documentation to go through but here are some quick tips and things we don’t think you should miss.

Naming Conventions
Naming conventions are very important when it comes to fields and sub fields (a field within another field group) so we make sure to use easily understandable yet descriptive names for each custom field. This way clients are able to relate the content they are adding with the name we’ve associated for the field.

Creating ACF Field

Repeaters
As mentioned above we’re able to create repeating elements which come in quite handy when a design has similar panels with differing content. The repeater is a set of sub fields that will can be repeated over and over again. The beauty lies in the user’s ability to edit the content within each repeater.

ACF Repeater

Flexible Content
Let’s say there are similar elements on a page but the layout differs depending on the content added. Simple! Use Flexible Content. You will have full control over the order and be able to add a limitless amount of layouts. It can look as simple as you need by only adding one sub field or much more complex by adding as many as you need.

Themes
ACF works with all WordPress themes and they have easy documentation to follow on how to set up ACF in your theme. At SplitMango we prefer to build with FoundationPress which integrates ACF quite nicely.

FoundationPress Yeti

What’s so great about ACF?
From a developer’s perspective it’s a good way to harness all the capabilities of custom fields and create a positive environment for clients. WordPress can be a confusing place for newer users and at SplitMango, ACF has allowed us to create a clean and positive experience for our clients.

If you’re interested in using this plugin you can download and install it through their website.

story written by Jacqui Janzen