People attending a funeral (or those unable to attend) often send flowers to the funeral home. Sometimes, however, a family will request that donations be made to a certain charity in lieu of flowers. There's some protocol involved in following this request; knowing it lets you express your sympathy properly.
Check the obituary (if there is one) for the deceased in the newspaper. Some obituaries will indicate if the family wants donations instead of flowers, and will indicate what charity to send checks to.
Ask a relative (not an immediate family member) of the deceased whether the family would prefer a donation to flowers. Asking a more distant relative will ensure you don't bother those grieving most.
Send a check to the desired charity. The donation amount is up to you, but it's customary to send an amount similar to what you would have spent on flowers.
Write out a card expressing sympathy for the family and include a line about how you've made a donation in the deceased's name. Send it to the family.
Wait for a response. Typically, the family will send a card, thanking you for the donation and the support.
It's also usually possible to make a donation through a charity's website.