change css classes acording to new terms in database