Why was Eleazar allowed to enter the Promised Land as he was born in Egypt and therefore should not have been allowed to enter?

All of the Levites (including El'azar) survived, as did all of the women and children. Plus Joshua and Calev.
The Levites survived: Talmud, Bava Bathra 121.

The women survived: Rashi commentary, Numbers 26:64.

The children survived: because the decree of dying in the wilderness applied only to men aged twenty and over (Rashi, Numbers 14:29).

See also:

The Exodus

Not all people were denied entrance to the Promised Land - those under twenty years of age were permitted to enter. It is therefore possible he was under that age. However, even more to the point is that Eleazar was a Levite. As such, he might not havebeen numbered among those who were to be excluded from entering the Promised Land - Levites were not included with the spies or in the census. It was the latter groups to which the exclusion applied.

First of all, it is reported that over ninety per cent of scholars do not believe that the Exodus from Egypt really took place as described in the Bible. This being the case, the story can be looked at from the perspective of a tradition or traditions that are not strictly historical.

Numbers 14:28-30 tells us that the Lord was angry with the Israelites for refusing to enter the Promised Land, after receiving the spies' report, saying that all those over twenty years old will die in the wilderness: "Say unto them, As truly as I live, saith the LORD, as ye have spoken in mine ears, so will I do to you: Your carcases shall fall in this wilderness; and all that were numbered of you, according to your whole number, from twenty years old and upward, which have murmured against me, Doubtless ye shall not come into the land, concerning which I sware to make you dwell therein, save Caleb the son of Jephunneh, and Joshua the son of Nun." Since Eleazar was already married before they left Egypt, he was clearly over twenty at this time and, like his father, Aaron, and uncle, Moses - Levites both - should have died in the wilderness.

The story of the Exodus from Egypt and conquest of Canaan is a complex mix of fragments from different sources, resulting in quite a few anomalies and inconsistencies. At times it was difficult for the Deuteronomist and the Redactor to harmonise all the different accounts they had to contend with. And in the end, Eleazar was somewhat essential to the story of the conquest of Canaan. Thus he was allowed to enter Canaan even though he was born in Egypt.