Q:

Where do you go when a Portal closes from the other side?

What would happen to the PCs who

 enter one of the elemental portals, with one of them wielding the elemental weapon, causing it to close when it touches?  Are the characters trapped on the elemental plane, where they must try to find another portal to escape, or are they forced back to the material plane, such as opposite what happens to the elemental princes when their portal closes.

Which plane do they end up on?

A:

They would be stuck in the elemental plane till they could find another way out.

Ask yourself, "If you walk through a door then some one closes it behind you, which side of the door are you on?"  

 A portal is the same concept except instead of being a door between 2 rooms, its a door between 2 planes.  It would be different if it was a spell that projected you to the elemental planes.  In that case your self isn't actually in the elemental plane, and if the spell got cut off the projection would disappear and you would wake up at your original location. This would be similar to what happens when the connection gets lost on a video call.  

