advanced-custom-fields

Populate select field after user input (Advanced Custom Fields)

喜欢而已 提交于 2021-01-29 21:11:49
问题 I have an option page with some fields. A repeater field that has 2 sub fields: DATE (datepicker field) and SESSION (select field with options: 1 and 2) And also 2 textarea fields that will be used to populate the TIME field in a frontend form. TIMES SESSION 1: 12:00 12:30 13:00 13:30 14:00 14:30 15:00 TIMES SESSION 2: 17:30 18:00 18:30 19:00 19:30 20:00 20:30 I have a frontend form with a DATE (datepicker) and a TIME (select) field. When a user selects a DATE in frontend that matches a DATE

Save custom post fields value before Woocommerce email send

核能气质少年 提交于 2021-01-29 20:57:30
问题 I have an issue regarding emails sent by Woocommerce. I have multiple custom fields, set up using the ACF plugin, for Wooocomerce orders. These fields contain additional info that should be visible in the emails sent to the user. But for some reason I can't get them to save before the email is send and thus the email is empty of those values. Only after I click resend email are the values visible. I tried prioritizing the action hooks using the Prioritize Hooks plugin but to no avail. Tried

Populate select field after user input (Advanced Custom Fields)

≯℡__Kan透↙ 提交于 2021-01-29 18:29:12
问题 I have an option page with some fields. A repeater field that has 2 sub fields: DATE (datepicker field) and SESSION (select field with options: 1 and 2) And also 2 textarea fields that will be used to populate the TIME field in a frontend form. TIMES SESSION 1: 12:00 12:30 13:00 13:30 14:00 14:30 15:00 TIMES SESSION 2: 17:30 18:00 18:30 19:00 19:30 20:00 20:30 I have a frontend form with a DATE (datepicker) and a TIME (select) field. When a user selects a DATE in frontend that matches a DATE

WooCommerce 4.0 custom checkout & ACF field value on email, admin order, and thank you page

怎甘沉沦 提交于 2021-01-28 17:52:30
问题 I'm having a hard time printing my custom field value to the email notifications, order admin and thank you page. I've browsed through StackOverflow, tried every single answer I found but unfortunately not working and I couldn't figure out the problem: I am trying to pass the value of the additional checkout field, it only prints the strong label with a blank value, and in the emails nothing shows, here is my code so far: //new pickup location checkout field add_action( 'woocommerce_before

WooCommerce 4.0 custom checkout & ACF field value on email, admin order, and thank you page

与世无争的帅哥 提交于 2021-01-28 17:47:28
问题 I'm having a hard time printing my custom field value to the email notifications, order admin and thank you page. I've browsed through StackOverflow, tried every single answer I found but unfortunately not working and I couldn't figure out the problem: I am trying to pass the value of the additional checkout field, it only prints the strong label with a blank value, and in the emails nothing shows, here is my code so far: //new pickup location checkout field add_action( 'woocommerce_before

Display product ACF fields on a specific WooCommerce email

為{幸葍}努か 提交于 2021-01-28 13:54:05
问题 So I almost got it, but this last detail of specifying WooCommerce emails is leaving my head in a bit of a knot here. I need to show ACF (advanced custom fields) fields of products (in this case it's a custom shipping time) But only in the new order email (processing order and waiting payment order sent to the client) and then new order email to admin. This was the main way I found: "Display product ACF field value in Woocommerce transaction emails" Thank you in advance @LoicTheAztec I also

Display product ACF fields on a specific WooCommerce email

醉酒当歌 提交于 2021-01-28 13:48:34
问题 So I almost got it, but this last detail of specifying WooCommerce emails is leaving my head in a bit of a knot here. I need to show ACF (advanced custom fields) fields of products (in this case it's a custom shipping time) But only in the new order email (processing order and waiting payment order sent to the client) and then new order email to admin. This was the main way I found: "Display product ACF field value in Woocommerce transaction emails" Thank you in advance @LoicTheAztec I also

save input values to localstorage & “bind” it with HTML element

杀马特。学长 韩版系。学妹 提交于 2021-01-28 11:51:32
问题 I painted this picture to demonstrate what my final goal is. Short description: If nothing is changed in form or there's already exact same values saved, "save values" button does nothing If something is changed in form, "save values" button saves those values to localStorage and bind with numbered element ( "1" in picture ) and with input it came from If numbered element is clicked, it fills the inputs that were changed with values that were saved If something is changed in form & it's not

ACF Query Posts by Repeater Field Not Empty

你离开我真会死。 提交于 2021-01-21 07:43:06
问题 This question seems to be unanswered on the internet, perhaps because it is not possible. I simply want to query all posts where the repeater field 'has rows'. i.e. $args = array( 'meta_query' => array( 'relation' => 'AND', array( 'key' => 'repeater_field', 'value' => '', 'compare' => '=!' ) ); I know an alternative is to run if statements inside the loop to filter them out, but that messes with some other logic which is based off of the number of posts in the query. Does anyone have any

How to pass custom fields into mapbox-gl js to create points on map?

眉间皱痕 提交于 2021-01-07 07:00:31
问题 I've created a map using mapbox and plotted multiple custom points that you can interact with. I am also using Wordpress and want to use advanced custom fields to create each point so they can easily be managed from a non-technical person. The fields are all setup, but I am having trouble passing them into the javascript in my php template. I've tried using a loop but I can't use the loop inside javascript. Here is my Mapbox code that I am using to plot the points and want to use advanced