The Old Wiseman of Desert Island claims the temple was buried by a violent sandstorm, although it seems to be a subterranean structure. When the temple is fully shown in the cinematics in LBA and on the cross-section of Twinsun in LBA2, it's shown that instead, it's floating on a piece of land in the planet's mantle. In LBA2 rollercoaster cinematics, the floating building is hinted to be a separate entity from the underground complex. How all these depictions coexist is not clear; it's possible that the Temple exists, or is a portal to, another dimension.
In LBA, Twinsen finds an old rabibunny at the entrance of the temple, that tells him to get the Book of Bù from inside the temple. Twinsen then enters the temple, that is guarded by skeletons and traps as falling rocks, and retrieves the book, proving he is the chosen one that the legend speaks of.
In LBA2, the temple has been turned into a touristic atraction called Temple Park, and a rollercoaster that Twinsen can ride has been installed. Later in the game, the Esmers take control of the temple and install a secret base in it. Twinsen can enter the temple from the old entrance to find lots of Kashes, and later he has to infiltrate the Esmer base to steal a shuttle to go to Emerald Moon. The base also has access through a secret passage in the Hacienda, but Twinsen can only use it when he is taken to Zeelich by the Esmers.
In both games, there are a lot of Kashes hidden in the Temple, so it also serves as a place to accumulate large sums of currency that are required further in the plot.