Title: codimex's Replies | WordPress.org

---

# codimex

  [  ](https://wordpress.org/support/users/codimex/)

 *   [Profile](https://wordpress.org/support/users/codimex/)
 *   [Topics Started](https://wordpress.org/support/users/codimex/topics/)
 *   [Replies Created](https://wordpress.org/support/users/codimex/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/codimex/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/codimex/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/codimex/engagements/)
 *   [Favorites](https://wordpress.org/support/users/codimex/favorites/)

 Search replies:

## Forum Replies Created

Viewing 15 replies - 1 through 15 (of 181 total)

1 [2](https://wordpress.org/support/users/codimex/replies/page/2/?output_format=md)
[3](https://wordpress.org/support/users/codimex/replies/page/3/?output_format=md)…
[11](https://wordpress.org/support/users/codimex/replies/page/11/?output_format=md)
[12](https://wordpress.org/support/users/codimex/replies/page/12/?output_format=md)
[13](https://wordpress.org/support/users/codimex/replies/page/13/?output_format=md)
[→](https://wordpress.org/support/users/codimex/replies/page/2/?output_format=md)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Forminator Forms – Contact Form, Payment Form & Custom Form Builder] Time field more user friendly?](https://wordpress.org/support/topic/time-field-more-user-friendly/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [5 months, 3 weeks ago](https://wordpress.org/support/topic/time-field-more-user-friendly/#post-18763049)
 * Thank you. I hope you improve the UX from that field soon. An AI has provided
   me with an interesting piece of code as a temporary fix, but it’s obviously better
   to have it implemented natively from your end.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Forminator Forms – Contact Form, Payment Form & Custom Form Builder] Time field more user friendly?](https://wordpress.org/support/topic/time-field-more-user-friendly/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [5 months, 3 weeks ago](https://wordpress.org/support/topic/time-field-more-user-friendly/#post-18762577)
 * Hi, Kris. Thank you for your quick response. Yes, my comment was about both dropdown
   AND number modes. I meant if you can implement something [like this](https://uxmovement.com/wp-content/uploads/2016/06/clock-widget-picking.png)(
   link marked as nofollow). A clock widget or something easier than clicking on
   two or three different fields. Users hate this. And it contrasts with the beautiful
   datepicker field with an intuitive calendar full of options (imagine typing the
   day, and then the month, and then the year). Does my point make sense?
    -  This reply was modified 5 months, 3 weeks ago by [codimex](https://wordpress.org/support/users/codimex/).
    -  This reply was modified 5 months, 3 weeks ago by [codimex](https://wordpress.org/support/users/codimex/).
      Reason: Typo
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Forminator Forms – Contact Form, Payment Form & Custom Form Builder] User registration forms – “user_register” action hook](https://wordpress.org/support/topic/user-registration-forms-user_register-action-hook/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [1 year ago](https://wordpress.org/support/topic/user-registration-forms-user_register-action-hook/#post-18486515)
 * Thank you for your answer. Figured out a different solution. Marking as resolved.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Forminator Forms – Contact Form, Payment Form & Custom Form Builder] Resend activation email – Wrong url link](https://wordpress.org/support/topic/resend-activation-email-wrong-url-link/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [1 year ago](https://wordpress.org/support/topic/resend-activation-email-wrong-url-link/#post-18483798)
 * Thank you! I’ll review those settings thoroughly. It’s a good starting point.
   Marking as resolved. Have a nice week!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Forminator Forms – Contact Form, Payment Form & Custom Form Builder] User registration forms – “user_register” action hook](https://wordpress.org/support/topic/user-registration-forms-user_register-action-hook/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [1 year ago](https://wordpress.org/support/topic/user-registration-forms-user_register-action-hook/#post-18483781)
 * Mmm… Didn’t think of triggering the native “user_register” hook after Forminator’s
   own hook. This might be tricky in combination of the email activation link (since
   the user is in a grey area of “being both registered and not registered yet”),
   but I’ll try to explore that. Anyway, I’m looking forward further updates on 
   this. Thank you!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[UpsellWP – Upsell and Related Products Offers for WooCommerce] Is it REALLY compatible with WPML?](https://wordpress.org/support/topic/is-it-really-compatible-with-wpml/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [1 year, 6 months ago](https://wordpress.org/support/topic/is-it-really-compatible-with-wpml/#post-18145769)
 * Oh! Thank you! I missed the “Syncing button” step. Thank you for your answer 
   with illustrative images. You have my 5-star review.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Pie Calendar - Events Calendar Made Simple] Combine two ACF date and time fields into a single date/time field](https://wordpress.org/support/topic/combine-two-acf-date-and-time-fields-into-a-single-date-time-field/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [1 year, 7 months ago](https://wordpress.org/support/topic/combine-two-acf-date-and-time-fields-into-a-single-date-time-field/#post-18111212)
 * After spending sooo many hours trying to figure it out, I finally came to a solution.
   Just in case someone faces the same issue. Disclaimer: I’m not an expert coder,
   and things probably could be done in a better way. Here it goes:
 * 1) In order to keep a frontend event submitter with four different fields (`start_date_acf`,`
   start_time_acf`, `end_date_acf` and `end_time_acf`), first you need to make sure
   that the ACF format of the fields are as follows:
    - `start_date_acf:` Y-m-d
    - `start_time_acf:` H:i:s (H:i also has proven to work for me)
    - `end_date_acf:` Y-m-d
    - `end_time_acf:` H:i:s (H:i also has proven to work for me)
 * 2) Then, I created two extra date/time fields (`start_datetime_acf` and `end_datetime_acf`),
   both with format `Y-m-d H:i:s`, to merge the respecitve start date and time fields
   and end date and time fields.
 * 3) Then, I added this code to make Pie Calendar fetching `start_datetime_acf`
   and `end_datetime_acf`:
 *     ```wp-block-code
       add_filter("piecal_event_query_args", function ($args, $atts) {$args["meta_query"] = ["relation" => "AND",["key" => "start_date_acf","value" => "","compare" => "!=",],];return $args;}, 10, 2);add_filter("piecal_start_date_meta_key", function ($key) {$key = "start_datetime_acf";return $key;});add_filter("piecal_end_date_meta_key", function ($key) {$key = "end_datetime_acf";return $key;});
       ```
   
 * 4) Then, I added this code, so that every time an event updates in the backend,
   the `start_datetime_acf` and `end_datetime_acf` fields are populated from `start_date_acf`,`
   start_time_acf`, `end_date_acf` and `end_time_acf` fields.
 *     ```wp-block-code
       function update_event_datetime( $post_id ) {if ( get_post_type($post_id) == 'product' ) {if ( wp_is_post_revision( $post_id ) )return;global $post;$start_datetime = (get_field('start_date_acf') . ' ' . get_field('start_time_acf'));update_post_meta($post_id, 'start_datetime_acf', $start_datetime);$end_datetime = (get_field('end_date_acf') . ' ' . get_field('end_time_acf'));update_post_meta($post_id, 'end_datetime_acf', $end_datetime);}}add_action( 'save_post', 'update_event_datetime', 10, 2 );
       ```
   
 * 5) Then, once the event is submitted from the frontend, just update it in the
   backend, and the two fields will be correctly merged and the calendar properly
   populated.
 * Probably not the most optimal solution, but it’s tested and works. The issue 
   is that if any of the events doesn’t have `start_datetime_acf` and `end_datetime_acf`
   field values populated, you’l get a fatal error (nothing too serious if you add
   those codes via Code Snippets plugin).
 * Thank you, and feel free to close this ticket, unless you come up to a better
   idea.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Pie Calendar - Events Calendar Made Simple] Combine two ACF date and time fields into a single date/time field](https://wordpress.org/support/topic/combine-two-acf-date-and-time-fields-into-a-single-date-time-field/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [1 year, 7 months ago](https://wordpress.org/support/topic/combine-two-acf-date-and-time-fields-into-a-single-date-time-field/#post-18098752)
 * Hi again. After burying CGPT with prompts asking for help, it’s stuck in a loop,
   suggesting once again the same code, which display all events piled up in the
   same cell (at the present moment, date and time). This is the shortest code I’ve
   got so far, based on your tutorial code, but unfortunately achieving the same
   wrong results. The first filter works fine, but the last two filters don’t pull
   the information from each post correctly:
 *     ```wp-block-code
       add_filter("piecal_event_query_args", function ($args, $atts) {$args["meta_query"] = ["relation" => "AND",["key" => "start_date_acf","value" => "","compare" => "!=",],];return $args;}, 10, 2);add_filter("piecal_start_date_meta_key", function ($key) {global $post;$key = date("Y-m-d H:i:s", strtotime(get_field('start_date_acf', $post->ID) . ' ' . get_field('start_time_acf', $post->ID)));return $key;});add_filter("piecal_end_date_meta_key", function ($key) {global $post;$key = date("Y-m-d H:i:s", strtotime(get_field('end_date_acf', $post->ID) . ' ' . get_field('end_time_acf', $post->ID)));return $key;});
       ```
   
 * I wish you can help me with finding directions towards the solution (considering
   I’m not an expert coder). Thank you!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Pie Calendar - Events Calendar Made Simple] Combine two ACF date and time fields into a single date/time field](https://wordpress.org/support/topic/combine-two-acf-date-and-time-fields-into-a-single-date-time-field/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [1 year, 7 months ago](https://wordpress.org/support/topic/combine-two-acf-date-and-time-fields-into-a-single-date-time-field/#post-18097003)
 * Thank you for taking the time to help. I feel we are really close to the solution.
   This is the furthest I’ve gotten by mixing your answer with my intuition:
 *     ```wp-block-code
       add_filter("piecal_event_query_args", function ($args, $atts) {$args["meta_query"] = ["relation" => "AND",["key" => "start_date_acf","value" => "","compare" => "!=",],];return $args;}, 10, 2);add_filter("piecal_event_start_datetime", function ($start_datetime, $post_id) {global $post;$start_date = get_field('start_date_acf', $post_id);$start_time = get_field('start_time_acf', $post_id);if ($start_date && $start_time) {$start_datetime = date("Y-m-d\TH:i:s", strtotime("$start_date $start_time"));}return $start_datetime;}, 10, 2);add_filter("piecal_event_end_datetime", function ($end_datetime, $post_id) {global $post;$end_date = get_field('end_date_acf', $post_id);$end_time = get_field('end_time_acf', $post_id);if ($end_date && $end_time) {$end_datetime = date("Y-m-d\TH:i:s", strtotime("$end_date $end_time"));}return $end_datetime;}, 10, 2);
       ```
   
 * Now, all the events are shown in the actual current date and time, all piled 
   in the same calendar cell (now’s date and time). If I refresh the page, the date
   and time of the event in the calendar also updates to match the actual date and
   time of this very moment. I’ve tried adding and removing `global $post;` but 
   no success. And after a series of prompts to CGPT, it has come to an almost identical
   version of your own original code. Any new ideas? Why are the filters ignoring
   ACF field values? Is it due to a ACF date or time field format? Might this line`
   Y-m-d\TH:i:s` be the culprit?
 * Thank you again for your willingness to help. I feel we’re really close to the
   solution!!!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Brevo for WooCommerce] Adding users to specific list via checkout opt-in checkbox](https://wordpress.org/support/topic/adding-users-to-specific-list-via-checkout-opt-in-checkbox/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [2 years, 7 months ago](https://wordpress.org/support/topic/adding-users-to-specific-list-via-checkout-opt-in-checkbox/#post-17150905)
 * Hi again. I’ve tried several approaches to solve this problem and I can’t figure
   out how to make it work. This is the most sense-making automation, so far:
    1. Custom event > order_completed
    2. Event data tracker > items > url > Contains > /en/
    3. **Contact attributes > OPT_IN > Is identical > Yes**
    4. Then, add the contact to “My Custom ENGLISH List”.
 * But this doesn’t work.
 * I thought today’s update 4.0.2 would fix the issue or at least cast light on 
   it, since the changelog reads “Bug fixes related to incorrect handling of opt-
   in status of shop customers in checkout flow”, but at this point, I have NO IDEA
   of how to add customers to a language-specific list when they check the opt-in
   checkbox in the checkout.
 * Any help? Anyone there? :/
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Loops & Logic] Listing elements with/out commas and “and” before the last element](https://wordpress.org/support/topic/listing-elements-with-out-commas-and-and-before-the-last-element/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [2 years, 10 months ago](https://wordpress.org/support/topic/listing-elements-with-out-commas-and-and-before-the-last-element/#post-16932451)
 * Thank you, Eliot! Didn’t know about the “If (not) last” trick!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[WPvivid — Backup, Migration & Staging] Exceeded I/O Usage](https://wordpress.org/support/topic/exceeded-i-o-usage/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/exceeded-i-o-usage/#post-16735135)
 * Thank you, Tony and Nicholas! Marking as resolved.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[WPvivid — Backup, Migration & Staging] Exceeded I/O Usage](https://wordpress.org/support/topic/exceeded-i-o-usage/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/exceeded-i-o-usage/#post-16729531)
 * Hi again, Nicholas. Your settings were successful, and the consumed resources
   actually decreased. They are now below the server usage limit. BUT for some reason,
   I got penalized again by my server host. It’s something I’m discussing with them
   at the moment.
 * I then reverted your settings to the default ones and tried a new backup. [Please, see this attached image](https://drive.google.com/file/d/1zpATx1yNp1WA3PEv5REL5Vs2w78yPHee/view).
   The peak on the left is your suggested settings. The peak on the right is after
   reverting them to default. The cyan lines show the limit was reached, which doesn’t
   make sense to me in the case of the left peak.
 * I just have one more question, before marking this as resolved, since your answer
   works: **could I migrate a website by uploading the files using your settings
   to another domain, as I usually do with the default settings? Will your restoring
   system automatically detect the difference in PDO, PCLzip, etc.?**
 * Thank you!!!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[WPvivid — Backup, Migration & Staging] Exceeded I/O Usage](https://wordpress.org/support/topic/exceeded-i-o-usage/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/exceeded-i-o-usage/#post-16727219)
 * Hi, thanks for your reply! Of course, I know you’re not in control of I/O usage
   in my server (“nobody” is), but the screenshot I attached shows a high peak in
   the moment I hit on the “Backup now” button. Let’s see if your settings provided
   can mitigate it a little. 🙏
 * Please keep this thread open a couple of days more until I come back with my 
   feedback after applying your settings. In the meantime, thank you again!!!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[PiWeb Disable payment method / Partial payment for WooCommerce] WPML compatibility?](https://wordpress.org/support/topic/wpml-compatibility-272/)
 *  Thread Starter [codimex](https://wordpress.org/support/users/codimex/)
 * (@codimex)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/wpml-compatibility-272/#post-16724455)
 * Hi again! This was quick! I just figured out how to do it: if you have, say, 
   two languages, then create two identical rules (with different names, as per 
   each language), and then click on the admin bar on each language, modifying the
   condition rules with each language’s category/product name, etc. (provided your
   taxonomies and product names are translated, too).

Viewing 15 replies - 1 through 15 (of 181 total)

1 [2](https://wordpress.org/support/users/codimex/replies/page/2/?output_format=md)
[3](https://wordpress.org/support/users/codimex/replies/page/3/?output_format=md)…
[11](https://wordpress.org/support/users/codimex/replies/page/11/?output_format=md)
[12](https://wordpress.org/support/users/codimex/replies/page/12/?output_format=md)
[13](https://wordpress.org/support/users/codimex/replies/page/13/?output_format=md)
[→](https://wordpress.org/support/users/codimex/replies/page/2/?output_format=md)