c# - Show another button where the original button was located -


currently in form starting @using (html.beginform have submit button this:

<input id="submitbutton" type="submit" value="update stuff" /> 

now after submit, want show button instead of button example:

<input id="continuebutton" type="button" value="continie next page" /> 

so understand should have property on model example @model.showsubmitbutton goes true or false. learning should close

@if(model.showsubmitbutton)     <input id="submitbutton" type="submit" value="update stuff" /> else     <input id="continuebutton" type="button" value="continie next page" /> 

but can't razor syntax wrong if way of doing correct begin it. need part. , want mvc, not js because don't know js yet.

use this

 @if(model.showsubmitbutton)  {     <input id="submitbutton" type="submit" value="update stuff" />  }  else  {     <input id="continuebutton" type="button" value="continie next page" />  } 

last not least hands dirty js


Comments

Popular posts from this blog

java - Static nested class instance -

c# - Bluetooth LE CanUpdate Characteristic property -

JavaScript - Replace variable from string in all occurrences -