Stability of a generalized quadratic functional equation in various spaces: a fixed point alternative approach