views:

307

answers:

2

I know the Html.Button has been moved to the Microsoft.Web.Mvc namespace, but I really miss the generic versions that used to exist in the early Previews.

All I want the Html.Button to do is to hit an action in my controller, but I'd rather not write the JavaScript in the onClickMethod argument.

In my previous project I just snagged the generic Html.Button code from a previous preview release, but that doesn't seem like the best approach as things progress. There were also Html.NavigateButton... where is that and why should I have to recreate it?

How is everybody else doing this?

+2  A: 

Yes, they really screwed up with Html.Button and Html.CheckBox in CTP5. I hope they return to the previous behaviour.

leppie
Oops: it seems the the question was edited while I replied.
leppie
I agree with your comment.. seems they took out a lot of good stuff.
Elijah Manor
+3  A: 

The problem with the generic versions is that filters are allowed to change the actual name of the action away from the name of the method (like the [ActionName] attribute).

Brad Wilson