FIXED without opening the Mac.
Not necessarily a capacitor issue. This conclusion tends to appear because 'some' iMacs had poor capacitors which would fail - I have two 2007 iMacs from new (in 2011) and neither has any failed capacitors.
My iMac ALS mid 2007 lost both firewire ports and ethernet at the same time whilst I was away and family were using it. The shutdown and reboot were also very slow. They had had a power cut which threw the whole house off although I did not connect the too events immediately (see below).
I did all the usual tests, reboot several times etc. TechTool Pro reported USB was OK but Firewire was not available on the Mac so could not test.... even though I had a Lacie HD attached that was lit up (powered by the Firewire port alone). Disc Utility could not see the Lacie. Ethernet (under Network Prefs) reported RED - no ethernet cable attached - even though one was attached and working (tested the cable on another Mac and refit it).
I booted from Install Disc and ran Apple Hardware Test - failed at 2.14 on the logic board test and stalled. At this point I was worried.
As a last ditch for the evening I reset the SMU - this is a microchip controller on the logic board which controls various power functions. For my iMac this was all cables out including power for 1 minute - put power cable back in WHILST HOLDING POWER BUTTON IN also. Then release power button, put keyboard, mouse and all cables back in and boot as normal.
Incredibly my Lacie appeared on the desktop and the reboot was fast, ethernet was green, web on and all is well. Nothing appears to be broken.
My conclusion to this is that the power cut, which blew two trips on my house board, maybe caused a surge which upset the Macs logic board. I did not have any surge protection on the computer cables (Doh!). Resetting the SMU cleared this immediately as far as I can see (I don't think it was a coincidence that it just started working again).
If you have these symptoms on an IMac G5 PPC try it - you've nothing to lose and it might clear the faults.