• Resolved OG-S

    (@og-s)


    Hi!
    Thank you for your great plugin. I’m trying to move the delivery date field in the order form. I would have it on the top of the order.

    I can remove it with:

    function remove_filters_with_method_name( $hook_name = '', $method_name = '', $priority = 0 ) {
        global $wp_filter;
        // Take only filters on right hook name and priority
        if ( ! isset( $wp_filter[ $hook_name ][ $priority ] ) || ! is_array( $wp_filter[ $hook_name ][ $priority ] ) ) {
            return false;
        }
        // Loop on filters registered
        foreach ( (array) $wp_filter[ $hook_name ][ $priority ] as $unique_id => $filter_array ) {
            // Test if filter is an array ! (always for class/method)
            if ( isset( $filter_array['function'] ) && is_array( $filter_array['function'] ) ) {
                // Test if object is a class and method is equal to param !
                if ( is_object( $filter_array['function'][0] ) && get_class( $filter_array['function'][0] ) && $filter_array['function'][1] == $method_name ) {
                    // Test for WordPress >= 4.7 WP_Hook class (https://make.www.ads-software.com/core/2016/09/08/wp_hook-next-generation-actions-and-filters/)
                    if ( is_a( $wp_filter[ $hook_name ], 'WP_Hook' ) ) {
                        unset( $wp_filter[ $hook_name ]->callbacks[ $priority ][ $unique_id ] );
                    } else {
                        unset( $wp_filter[ $hook_name ][ $priority ][ $unique_id ] );
                    }
                }
            }
        }
        return false;
    }
    
    remove_filters_with_method_name( 'woocommerce_after_order_notes', 'ddfw_delivery_options', 10 );

    Now I need to see the field on the top of page
    Probably with the hook woocommerce_before_checkout_form

    I’ve tried

    add_action( 'woocommerce_after_order_notes', 'ddfw_delivery_options')

    How can I achive this?

    Thank you in advance

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author pixlogix

    (@pixlogix)

    Hello @og-s sorry for delay reply hope you are doing well can you please explain in details with screenshots also if possible can send an email on here([email protected]) with your credentials so we can help you with this issue

    Plugin Author pixlogix

    (@pixlogix)

    Hello @og-s hope your issues are resolved with this new update please let us know if you have any other issues always happy to help you

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Moving the date field in the order form’ is closed to new replies.