Added "global $conf" to make the conditions working.