Digital potentiometer with op amp

I know this topic was published a while ago, but I have a question. I am fairly new to digital electronics applications and I ran into some problems for power supplies in Op-Amps. For this very operational amplifier LM 324N I am supplying 15 Volts 300 mA to pins 4 and 11 respectively. when I do that the IC is getting heated up ALOT! I have tried to create a simple voltage divider to supply 12 volts or so, but in that case the IC is not even on. How can I overcome this issue? And also polymorph mentioned that all not connected pins have to be connected, I am curious why this is.

Thank you.