My Mac has never worked properly since I got it, as its internal battery, which keeps PRAM data, was dead. PRAM stores a lot of information (more than you could imagine, if you come from the PC world), so losing its data is very annoying (aside of producing strange system problems). So I decided to fix it today.
The first step is to reach the battery; in the Mac model I have, it's just a matter of removing the motherboard through the back tray, and detach the battery from it. Next you have to buy a replacement battery, after checking the one you need. In my case, it's a Rayovac 840, which costs more than 12 euros. Ew... I don't want to spend that amount of money - when there are other solutions - for a computer I'll use only to play with NetBSD/mac68k.
So I've picked up three alkaline and non-rechargeable AA batteries (also named R6) and soldered them together in series, producing a total of 4.5V. Then picked up the wire from the original battery and used it to connect this home-built one. Plugged it, replaced the motherboard and powered up the system. All done! I hope it keeps working properly for a long amount of time ;-)
If you are going to do this, be aware that some models use 3.6V batteries (so two AA batteries should be enough). And remember that you do it at your own risk.