gmdate() warnings after trying to set up a numeral converting function
-
I am using a function to convert all the Latin numerals on my site to Devanagari ones :
function DevNumDate ($text) { $text = str_replace('1', '१', $text); $text = str_replace('2', '२', $text); $text = str_replace('3', '३', $text); $text = str_replace('4', '४', $text); $text = str_replace('5', '५', $text); $text = str_replace('6', '६', $text); $text = str_replace('7', '७', $text); $text = str_replace('8', '८', $text); $text = str_replace('9', '९', $text); $text = str_replace('0', '०', $text); return $text; } add_filter('get_date', 'DevNumDate'); add_filter('get_the_date', 'DevNumDate'); add_filter('get_the_time', 'DevNumDate');
But, this gives me too much warnings like :
Warning: gmdate() expects parameter 2 to be int, string given in /home/user/domains/<domain>/public_html/wp-admin/includes/dashboard.php on line 977 Warning: gmdate() expects parameter 2 to be int, string given in /home/user/domains/<domain>/public_html/wp-admin/includes/dashboard.php on line 975 Warning: gmdate() expects parameter 2 to be int, string given in /home/user/domains/<domain>/public_html/wp-admin/includes/dashboard.php on line 973
How can I nuetralize those warnings ?
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
- The topic ‘gmdate() warnings after trying to set up a numeral converting function’ is closed to new replies.