That is an odd problem. The best solution is to first try another battery, as the problem can only be the logic board or the battery. If the battery doesn't fix it, you have a logic board issue. Batteries for the iBook can be purchased at the link below:
http://www.powerbookmedic.com/xcart1/cu ... hp?cat=372
-Bradley
PowerbookMedic