tags:

views:

589

answers:

2

I am looking for Html.SubmitImage in RC1 and don't see it anywhere when reflecting through the MVC assemblies.

Has it been moved / removed?

+1  A: 

SubmitImage has moved to MvcFutures in RC1. You can find the actual source at http://www.codeplex.com/aspnet. The RC1 changeset is at http://aspnet.codeplex.com/SourceControl/changeset/view/21528

tvanfosson
But what does that mean? Will it be implemented in the future? Is it just an idea that might possibly come back in the future? Is it safe/advisable to add it into my local source code?
Nick DeVore
Sorry. I don't have any particular insight into the MVC teams plans.
tvanfosson
+1  A: 

For others, this is a quick mockup of a SubmitButton extension for the HtmlHelper.

public static class HtmlLinkExtensions
{
    public static string SubmitButton(this HtmlHelper htmlHelper, string imageLink, string value, string altText)
    {
        return string.Format("<input type='image' src='{0}' value='{1}' alt='{2}' />", imageLink, value, altText);
    }
}
Dan Atkinson