submit a form vs refresh a form

Hi there,

I am new with rails and html stuff.
I have difficulty to understand the differences if I submit a form and refresh the same form, are they doing the same action?

For example,
I bought some books and then I submit a form of payment. If I refresh it again, would it resubmit a form of payment again? So user will get charge twice?
How I can avoid user to resubmit a page with refresh? or how my code can capture what is user doing? refresh the page or submit a form?

Thanks,
Yudi Soesanto