$personal0 = $DB_site->query_first(" SELECT SUM(views) AS personalviews FROM thread WHERE postuserid='$userinfo[userid]' AND open!='10'"); $personal= 2*$userinfo[posts]+$personal0[personalviews]; if ($personal0 == ""): $personal0 = "0"; endif;