WC_Data::__toString()
Change data to JSON format.
Method of the class: WC_Data{}
No Hooks.
Return
String
. Data in JSON format.
Usage
$WC_Data = new WC_Data(); $WC_Data->__toString();
Changelog
Since 2.6.0 | Introduced. |
WC_Data::__toString() WC Data:: toString code WC 9.6.1
public function __toString() { return wp_json_encode( $this->get_data() ); }