Global and blow-up solutions for a heat equation with variable reaction