OK the ibook doesn't see the HD and the optical drive but when you power the ibook do you have video onscreen and does it show the question mark folder icon ? If yes then check the cables connections both ends as rdklincorporated suggess. If the HD, the optical drive and the cables are in good condition then the IDE circuitry on the logic board could be faulty.
Since you've been able to boot from an external drive then AC adapter and the DC in board should be OK so I don't think it could be a power supply issue.