Support » Plugin: Event Manager and Tickets Selling Plugin for WooCommerce » How to add Advanced Custom Field (ACF)
How to add Advanced Custom Field (ACF)
-
Can I add a custom field defined by ACF plugin?
Or in some other way
-
Yes. It works.
Simply follow the ACF documentation: https://www.advancedcustomfields.com/resources/code-examples/
Hi !
Could you please tell me more about how you proceeded ? I would like for custom fields to appear in the sidebar but I can’t find how to add it to the theme.
Hi, @cgigi. How are You?
First of all, you need to create a new template of Woocommerce Event Manager. Just follow this tutorial, https://demo.vaincode.com/mage-event/documentation/how-to-create-new-theme-template/ (is very easy!). Then you can modify your template as you need, inserting your custom field where you need following the ACF documentation (https://www.advancedcustomfields.com/resources/code-examples/).
Then… Voilà!
🙂
Hi,
Thank you very much for your reply. I’m sorry to bother you again but I have very little knowledge when it comes to coding and I’m stuck. I managed to create a personalized template based on the default template. I’ve put the cart section in the side bar and I’d like for personalized fields to appear below it (i want to make a list of event’s highlights in the single view).
I’ve looked at the ACF link you sent but i’m afraid I lack knowledge to make it happen.
Here is the extract of the code in my template but of course it doesn’t work because the line of code for the personalized fields isn’t enought code I think. Would you happen to know what I should write below the cart section code please ?</div> <div class="mep-default-sidebar"> <?php if ($hide_location_details == 'no') { ?> <div class="mep-default-sidrbar-map"> <h3> <?php echo mep_get_option('mep_event_location_text', 'label_setting_sec') ? mep_get_option('mep_event_location_text', 'label_setting_sec') : _e('Event Location:', 'mage-eventpress'); ?> </h3> <?php do_action('mep_event_map',get_the_id()); ?> </div> <?php } ?> <div class="mep-default-feature-cart-sec"> <?php do_action('mep_add_to_cart', get_the_id()) ?> </div> <strong><p><?php the_field('denivele'); ?></p></strong>
Again I’m sorry to bother you. This is the last change I want to make to my template and It’d be great if you could help me out with that.
-
This reply was modified 1 year, 8 months ago by
cgigi.
-
This reply was modified 1 year, 8 months ago by
- The topic ‘How to add Advanced Custom Field (ACF)’ is closed to new replies.