M
M
Muxammadislom Eshonqulov2021-08-05 11:09:44
WordPress
Muxammadislom Eshonqulov, 2021-08-05 11:09:44

Adding acf gallery to dokan plugin?

Good time.
Added custom field via acf + Dokan plugin.
Through the function acf_form(); I want to display a form so that the seller, when adding a new product, can add pictures through an arbitrary acf field.
Added this code to the new_product.php file form from the Dokan plugin.

<?php while ( have_posts() ) : the_post(); ?>
  <?php acf_form(array(
    'id' => 'MytestForm',
    'submit_value'  => __('Update meta')
  )); ?>
  <?php endwhile; ?>

Now the page does not open errors, only page loading does not give errors either. I removed the while loop, leaving only the acf_form function, the page opens but does not display anything. Added to header.php Tell me who knows thanks for the answer.
<?php acf_form_head(); ?>

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question