The story goes something like this : Lord Shiva and Godess Parvathi had decided to find suitable brides for their sons, Ganesha and Muruga. There was an argument on among both their sons as to who was to get married . Lord Shiva informed them both that of the two, the one who would traverse round the world in Pradakshinam , would be the one to get married off first. Indeed , interestingly enough, both set off on their journey around the world, and by the time Lord Muruga could actually not take even one complete round of the world on his vahana( vehicle ), Lord Ganesha had already taken seven rounds of his parents, (for according to Sastras, going in pradakshinam round one's parents is equivalent to going once round the world (Boopradakshinam).
Therefore , Lord Shiva went ahead and got Siddhi & Buddhi, the daughtersof Viswaroopan married to Lord Ganesha. Muruga, on returning from his long journey round the world, was shocked and angered to learn of the developments. In his state of fury , he went away to stay alone on Mount Kravunja in the name of Kumarabrahmachari. Later, on seeing Lord Shiva coming over to soothe and console him, he tried to move to another location, but on the request of the Devas, stayed at a nearby place. And the actual place where Lord Shiva and Godess Parvathi had come to stay is now known as Sri Sailam. It is believed that even today, Lord Shiva visits Lord Muruga on the Amavasya day & Parvathi Mata on the Pournami day.
The temple which stands a testimony to all these happenings at this holy place is constructed facing the east direction, with the central portion consisting of several pillars , and a huge idol of Nadikeswarar