Normally a vamp is only forbidden from entering a person's home without permission. Presumably Jenny and Willow do magic to also ban him from Cordy's car and the school as well as withdrawing his ability to enter Buffy's house. However it doesn't work at the school due to the inscription on the building inviting in all those who seek knowledge.