get_var is neither a string, integer, or array …? August 25, 2022 by Tarik Billa var_dump($vote_count) should tell you what type $vote_count is. Probably you’re getting NULL.