If you don't use your laptop for long periods of time (4 weeks or more), remove the battery from the laptop. You should re-install the battery every 4 weeks and allow it to fully charge, then discharge completely. This is more important if you have a nickel-metal hydride battery (NiMH)
New batteries should be fully charged before use and fully charged/discharged (cycled) 3 times before it will run at full capacity.
Leaving a battery in a laptop while plugged in to the mains for long periods of time will keep the battery in a constant state of charging up which will reduce the life cycle of the battery.