Your post sounds confusing. A carboy is a glass or clear plastic jug which looks like a 5 gallon water bottle. I think you mean you're using a fermenting bucket with a lid that has a grommeted hole for an airlock.
How long has your beer been in your fermenter? If there was a big enough time gap between the initial bubbling of the airlock and the time you noticed beer on the lid of your bucket, it is likely that fermentation has completed. Fill the airlock to the fill line and sit to watch for bubbling for about 5 minutes.
Your beer should be fine, but next time use a blow off tube. A blow off tube is simply a vinyl tube that comes out of the center tube of the airlock; you will need a few feet of 7/16 tubing. Run this tubing to a seperate vessel ( I use a half-filled gallon of water), and submerse the end of the tube in water. This will allow a violent fermatation to push foam through the tube while keeping oxygen out of your fermenter.