I’d like to add a simple ACF text field to a page but would I would like to wrap some custom code (a div with class element) around this text field, is this possible – example below.
content of the ACF text field would be place here
I’d like to add this code to the ACF field rather than in my page template as I’d like to use the flexible field, letting the user build the page in blocks.
Many thanks for any help,
<?php the_field('field_name'); ?>
or did i get your question all wrong 🙂
Thank you for replying but yes, you did get the question wrong 😉
It’s the code for the div that I wanted to ‘wrap’ around the custom field.
I wanted to have a series of text boxes the user could choose from using the flexible content field, each with a different div/class code invisibly wrapped around the chosen field.
Thank you for answering though, I do appreciate it.