You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Can't for the life of me figure out why I'm getting this error.
<?phpnamespaceLib;
useStoutLogic\AcfBuilder\FieldsBuilder;
$content = newFieldsBuilder('single_client_results');
$content
->setLocation('post_type', '==', 'client-results');
$content
->addTab(__('Client Info', 'zoey'))
->addImage('client_logo')
->addWysiwyg('client_description')
->addTab(__('Case Study Info', 'zoey'))
->addWysiwyg('the_problem')
->addWysiwyg('the_solution')
->addWysiwyg('the_results')
->addImage('victory_image', [
'instructions' => __('This image is displayed alongside "The Results" field. It should be an image of the client in a state of victory after the solution has impacted their business.', 'zoey')
])
->addTab(__('Work Samples', 'zoey'))
->addFlexibleContent('work_samples');
foreach(
get_posts([
'post_type' => 'services',
'number_posts' => -1
]) as$service
) {
$content
->modifyField('work_samples', function($fieldsbuilder) {
$fieldsbuilder
->addLayout($service->post_name, ['label' => $service->post_title])
->addText('title', ['default_value' => $service->post_title])
->addFields(
field_partial_exists("layouts.$service->post_name") ?
get_field_partial("layouts.$service->post_name") :
get_field_partial('layouts.gallery')
);
return$fieldsbuilder;
});
}
return$content;
gives me the error:
PHP message: PHP Fatal error: Uncaught Exception: No such function: addLayout in ...vendor/stoutlogic/acf-builder/src/ParentDelegationBuilder.php:69
The text was updated successfully, but these errors were encountered:
Can't for the life of me figure out why I'm getting this error.
gives me the error:
PHP message: PHP Fatal error: Uncaught Exception: No such function: addLayout in ...vendor/stoutlogic/acf-builder/src/ParentDelegationBuilder.php:69
The text was updated successfully, but these errors were encountered: