I do what Z does... we must use the same kind of hairspray

I bet some hot water will loosen most anything that would be sprayed from a bottle like that. You might have to take apart the sprayer nozzle, and the hose, but I'm confident you can manage...
I just bought 2 new ones, empty, at the dollar store for (guess how much!) $1.00 each!... Needed them for my plants, and couldn't find one under the sink that I felt could be cleaned well enough to not hurt the plants. Didn't even think about them being so gummed up they wouldn't spray anyway!