Ajax confusion

I'm a bit confused about ajax. If I have a link, do I add the href,
data-remote="true" and data-method in there? Or do I make the actual
call in a separate script with $.ajax({})? Or both?

The same thing with a form. Is that suppose to have an action path and
an jquery axaj url: "..." path at the same time?