Todays feast commemorates the dedication of the Church of Saint Mary, which was built near the Temple Mound in Jerusalem. In both the Eastern and Western Churches this is the day recognized traditionally as the day Mary was presented at the Temple.
The church itself was destroyed, some accounts say by an earthquake in the seventh century, and the ruins were converted into a mosque by Abd El-Wahd in the early eighth century. Muslims believe that this mosque replaced a larger, more ostentatious mosque on this site where Mohammed ascended to heaven, but history does not bear this out, as the church is known to have been built by Justinian and was not destroyed until several years after Mohammed's death.
Why was Mary presented at the temple? Christ was presented at the temple because under Jewish tradition the first born son was presented to God. It was an ancient tradition. Girls were not.
According to legend Anna and Joachim offered Mary to God in the Temple when she was three years old. This was to carry out a promise made to God when Anna was still childless. This is recorded in the apocryphal the Protoevangelium of James, though the account is not scriptural the story persists in both the Eastern and Western Churches.