Worldchanging considers the carbon footprint of solar panels and finds that they save a lot of energy and carbon:
A recent life-cycle analysis published at the Institute of Science in Society (ISIS) showed that in a nice sunny place like Spain, PV panels reach energy payback (when they've saved as much fossil fuel as it took to make them) in about one to three years, depending on the type of panel.
A commenter points out that this issue is a bit of a red herring as the
manufacturing and the processes to make solar cells will be using the sun's energy directly to make these products with NO carbon footprint. A totally green process is all in the news RIGHT NOW as one solar company after another announces installation of their own solar panels for their total energy manufacturing consumption.
It should be noted that the life-cycle impact also considered the effects of mining, processing of materials, etc.