PHP error in functions.php
Closed this issue · 1 comments
mbomb007 commented
Warning: A non-numeric value encountered in /var/www/html/wp-content/themes/suffusion/functions.php on line 148
That code:
$header_args['width'] = $options['suf_main_col_width'] + $options['suf_sb_1_width'] + $options['suf_sb_2_width'];
The error comes about if the Default Sidebar Layout settings have empty string in for those values. This is unexpected, because the field descriptions state:
Enter the number of pixels here (don't enter 'px'). Non-integers will be ignored. Incompatible values will be treated as [number]
So despite this message, the defaults are not taken into account when left empty, and errors occur.
Good news: the workaround is to simply put the default value into the settings instead of leaving empty.
marcissimus commented