Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>You can make next and previous submit buttons. If you give them the same name (in code below I used "PageToGo") then you can add a corresponding string to your model with that name, and on submission you can determine which page to go to next.</p> <p>As for the question links, if you need them to post answers I see only two solutions.</p> <p>1) If you know javascript will be enabled, then upon any link clicks, either post the page with ajax then proceed to the link upon success, or save the links question number into your form then post the form.</p> <p>If you do the latter idea you'd have something like</p> <pre><code>if(model.PageToGo == "Next") newPage = currentPage + 1; else if(model.PageToGo == "Previous") newPage = currentPage - 1; else newPage = int.Parse(model.PageToGo); </code></pre> <p>If you can't assume javascript is enabled, the only solution I can think of is to make all your links submit buttons and then make them look like links with css.</p> <p><b>Edit:</b> Looking at your new requirements/code, my advice is that language and questions should not use the same Action. Instead, have both of them inherit a base model that contains all your menu data, and create a shared view that both of them use that creates the menu of submit buttons.</p> <p>It sounds like you're trying to partially submit a webpage the way you can partially submit Windows Forms. I don't know if that's possible, unless you use ajax/javascript. Using the method I described, you'll still be posting the entire page, but if you have different actions handling the posts of questions/ language, it will be easier to process each one.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload