Bonding has to do with a parent's tie to the infant that occurs in the first hours of life. That may be a magic moment for parents, but the newborn's brain is not yet ready for establishing a relationship, so there is no reason to believe that the first contact is meaningful for the infant.
The term "attachment" refers to a relationship between a baby and his parent that develops gradually and builds over a long period of time. Both parties take a role in the relationship; you could call it a lifelong partnership.
Although all that goes on between a parent and child in the first six months of life is important to developing attachment, it is of no greater significance than what goes on in later weeks and months.
Because this process is one of building a long-term relationship, even infants who did not have immediate contact with their parents (due to adoption, illness, or premature birth) can become securely attached. Even attachments that are not secure at the end of the first year may change for the better if circumstances improve.
Infant/caregiver attachment is built upon all that is shared over the weeks, months, and years of early childhood.