I recently had a little snafu with a button link. I was using an anchor around a button to replace a form submission if the user wasn't registered.
<% if user_signed_in? %>
<input type="submit" value="Do Action">
<% else %>
<a href="/sign_up">
<button>Sign Up to Do Action</button>
</a>
<% end %>
The problem was that when I clicked it, it made a random POST request to the current path. Wut?? Turns out the problem was that HTML buttons have types. You'd be wise to follow the specification.
There are 3 types of buttons according to the W3C spec. The "submit", "reset", and "button" buttons.
<form>
<button type="submit">Submit Form</button>
<button type="reset">Reset this Form</button>
</form>
<a href="/important/stuff">
<button type="button">Important Stuff</button>
</a>
Long story short, make sure to specify type="button" when you want a plain old button link.