Warning: Array to string conversion in /mnt/data/home/502433.cloudwaysapps.com/rhbymdevka/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 808
Warning: foreach() argument must be of type array|object, string given in /mnt/data/home/502433.cloudwaysapps.com/rhbymdevka/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 813
Warning: Array to string conversion in /mnt/data/home/502433.cloudwaysapps.com/rhbymdevka/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 808
PUM_Utils_DataStorage::get_data_formats( mixed $value )
Derives the formats array based on the type of $value.
Description Description
Warning: Array to string conversion in /mnt/data/home/502433.cloudwaysapps.com/rhbymdevka/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 808
Warning: foreach() argument must be of type array|object, string given in /mnt/data/home/502433.cloudwaysapps.com/rhbymdevka/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 813
Warning: Array to string conversion in /mnt/data/home/502433.cloudwaysapps.com/rhbymdevka/public_html/wp-content/themes/wporg-developer/inc/template-tags.php on line 808
Parameters Parameters
- $value
-
(Required) Value to store.
Return Return
(array) Formats array. First and last values will always be string ('%s').
Source Source
File: classes/Utils/DataStorage.php
public static function get_data_formats( $value ) { switch ( gettype( $value ) ) { case 'integer': $formats = array( '%s', '%d', '%s' ); break; case 'double': $formats = array( '%s', '%f', '%s' ); break; default: case 'string': $formats = array( '%s', '%s', '%s' ); break; } return $formats; }
Expand full source code Collapse full source code View on Trac