$relatedinfo = fetch_foruminfo($val);
if (! ($relatedinfo['options'] & $_FORUMOPTIONS['active']) ) { // forum isn't active continue; }