woocommerce_thankyou_order_id

woocommerce_thankyou_order_id

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: woocommerce.9.5.1

apply_filters('woocommerce_thankyou_order_id') is found 2 times:

  • /includes/gateways/paypal/includes/class-wc-gateway-paypal-pdt-handler.php line 106
    	 * @deprecated 6.4 Use check_response_for_order instead.
    	 */
    	public function check_response() {
    		global $wp;
    		$order_id = apply_filters( 'woocommerce_thankyou_order_id', absint( $wp->query_vars['order-received'] ) );
    
    		$this->check_response_for_order( $order_id );
    	}
    
    	/**
    	 * Check Response for PDT.
    
  • /includes/shortcodes/class-wc-shortcode-checkout.php line 270
    	private static function order_received( $order_id = 0 ) {
    		$order = false;
    
    		// Get the order.
    		$order_id  = apply_filters( 'woocommerce_thankyou_order_id', absint( $order_id ) );
    		$order_key = apply_filters( 'woocommerce_thankyou_order_key', empty( $_GET['key'] ) ? '' : wc_clean( wp_unslash( $_GET['key'] ) ) ); // WPCS: input var ok, CSRF ok.
    
    		if ( $order_id > 0 ) {
    			$order = wc_get_order( $order_id );
    
    			if ( ( ! $order instanceof WC_Order ) || ! hash_equals( $order->get_order_key(), $order_key ) ) {