Updating value html

After that Model State/POST values provide the display value.

The default behavior should be fine for 99% of binding scenarios.

If it's not I want to reset the email address back to the old value which exists in the database and was previously store.

The obvious thing to do would be to modify the model.

You do want to get the POST values back into your input controls at all times, so that the data displayed on a form for the user matches what they typed.

The relevant markup is the email address which needs to be manipulated via the model in the Controller code.

Updating the model for display purposes in a POST has in effect - no effect.

After getting quite a few comments on this post I quickly realized that the behavior I described above is actually the behavior you'd want in 99% of the binding scenarios.

binding causes the associated DOM element to display the HTML specified by your parameter.

Typically this is useful when values in your view model are actually strings of HTML markup that you want to render.

Leave a Reply

Your email address will not be published. Required fields are marked *

One thought on “updating value html”

  1. Digitized by the Internet Archive in 2013 The Official Organ of the Students of the University of the South A Legacy of 103 years of Student Journalism SEPT 5, 1994 VOLUME CLXXIV, NO.