Jordan occupied part of it, and Israel the rest, and then Israel occupied it all. It was all illegal. Just because Jordan did something illegal doesn't mean what Israel did was legal. Acquiring territory by means of war is ALWAYS illegal.
Hamas calls for 'day of rage' at Temple Mount, Al-Aqsa in wake of deadly West Bank murder (Haaretz)
from the article: Israel can't put occupation up for immoral referendum