Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

save form in asp.net mvc

@Html.ValidationSummary(true)


<fieldset>
    <legend>WorkType</legend>

    <div class="editor-label">
        @Html.Label("Work Type")
    </div>
    <div class="editor-field">
        @Html.TextBoxFor(model => model.Type)
        @Html.ValidationMessageFor(model => model.Type)
    </div>

    <div class="span7">
        <input type="submit" value="Create" class="span2 btn btn-default" />
        <button type="button" onclick="location.href='@Url.Action("Index", "Slider")'" class="btn btn-primary">
            Back to List
        </button>
    </div>
</fieldset>
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #save #form #mvc
ADD COMMENT
Topic
Name
5+4 =