set proper header for javascript