• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

"properties should not be accessed directly" issue during WooCommerce 3.0 checkout

phpwordpressobjectwoocommercecheckout


PHP Snippet 1:

    $OrderID= ( WC()->version < '2.7.0' ) ? $order->id : $order->get_id();
    $shipping_country   = (  WC()->version < '2.7.0' ) ? $order->shipping_country : $order->get_shipping_country();

Related Snippets

LARAVEL: How to fetch id dynamically in a query builder?

Add customer email and phone in "Order" column to admin orders list on Woocommerce

Read users and passwords from a txt file

add " ? " in url via htaccess RewriteRule

Limit login attempts in Laravel 5.7

Apply filter array/return terms

Object of class stdClass could not be converted to string error

SQLSTATE[HY000]: General error: 1 table posts has no column named *

SlimExceptionHttpNotFoundException

display WooCommerce “Add to cart” button with short-code [add_to_cart ] dynamically

Passing PHP JSON to Javascript: echo json_encode vs echo json declaration

How do I do HTTP basic authentication using Guzzle?

phpunit - mockbuilder - set mock object internal property

Laravel-fopen: failed to open stream: Permission denied

Laravel unique validation on multiple columns

About Contact Privacy policy Terms and conditions