A merchant takes you information (electronically or another method), gets verification of your information and tells the store clerk to let you out of the store with the stuff you want.
Then the merchange transmits a file to the credit card processing company who then pays the merchant.
You then get a bill for what you bought and you pay the bill.