As I recall, the selective part is due to the high salt content - many microbes cannot survive on it. If something grows it must have some tolerance for the high salt.
The differential part is down to the mannitol substrate and the red indicator used in it. If an organism can ferment the mannitol, it will turn the indicator yellow. If it cannot ferment it, the media stays red.