It was estimated that the heat inside the core of the Sun inside around 15 000 000 °C - this value is extremely enormous. How did scientists estimate this value?
The composition can be determined by taking spectra. Additionally, the mass can be determined through dynamics. If you combine these two, under the assumption that the star is in a state of hydrostatic equilibrium (which means that the outward thermal pressure of the star due to fusion of hydrogen into helium is in balance with the inward tug of gravity), you can make statements about what the temperature and density must be in the core. You need high densities and high temperatures in order to fuse hydrogen into helium.
Remember what's happening: Temperatures are hot enough for hydrogen in the core to be completely ionized, meaning that in order to fuse these protons into helium nuclei, you need to overcome the electromagnetic repulsion as two protons come close (like charges repel). Below is a diagram of the process of one particular type of fusion (Proton-proton chain reaction).
The other fusion reaction which occurs at the cores of stars is called the carbon-notrogen-oxygen (CNO) cycle, and is the dominant source of energy for stars more massive than about 1.3 solar masses. Below shows this process.
EDIT: Somebody pointed out that this doesn't actually answer the question at hand - which is true. Forgetting how to do some of the basic back of the envelope calculations myself (I admit, stellar astrophysics is definitely not my specialty), I've stumbled across a very crude and simple estimation of how to calculate the central pressure and temperature of the sun from. The calculation does however point out the correct values and what one would need to know in order to get the details correct.
Hydrodynamic models of the Sun allow one method of estimating its internal properties. To do this, the Mass, radius, surface temperature, and total luminosity (radiative energy emitted)/s of the Sun must be known (determined observationally). Making several assumptions, e.g., that the Sun behaves as a fluid and that local thermodynamic equilibrium applies, the stellar equations of state can be used. Numerical methods are applied to these equations to determine the internal properties of the Sun, such as its central temperature.
A great example for how to work this problem your self can be found in the undergraduate text, 'An Introduction to Modern Astrophysics' by Carroll and Ostlie (Section 10.5). The FORTRAN code to run your own stellar model is included in Appendix H.
A comprehensive review paper on how stars of different masses evolve internally (e.g., with respect to T, P, etc.) that is worth reading is: http://adsabs.harvard.edu/abs/1967ARA%26A...5..571I
A very interesting historical overview of the development of the Standard Solar Model: http://arxiv.org/abs/astro-ph/0209080
This (admittedly dry) paper gives you a good idea of how well the 'standard' solar models estimate the internal properties of the Sun using helioseismology and neutrino measurements to help tie down their boundary conditions: http://adsabs.harvard.edu/abs/1997PhRvL..78..171B The answer is that they match incredibly well (>0.2% error)
These were the least technical (but still academically published) references I could find.
Here is a comprehensive page on the state-of-the-art in solar modelling and measuring the internal Sun using Helioseismology: http://www.sns.ias.edu/~jnb/Papers/Preprints/solarmodels.html (highly technical)