Tagged Questions
3
votes
3answers
107 views
Versioning an API
I'm starting a side project, the first stage will be a building a web application with MVC, in later stages we will be adding clients for mobile platforms. My thought was to create one API that all of ...
1
vote
2answers
106 views
MVC : Does Code to save data in cache or session belongs in controller?
I'm a bit confused if saving the information to session code below, belongs in the controller action as shown below or should it be part of my Model?
I would add that I have other controller methods ...
1
vote
0answers
135 views
Reusing values for segment variables when generating outbound URLs
When routes are matched to the outbound URLs, the routing system will try to find values for each of the segment variables in route's URL pattern by also looking at the values from the current ...
0
votes
1answer
273 views
Implementing a Service Layer with MVC4 while honoring Single Responsibility
I'm trying to learn some best practices while I ramp up on MVC4. I have a solution with three projects:
Web: MVC stuff
Core: Data Model
Tests: Testing classes
I'm now trying to add:
Services: ...
0
votes
0answers
32 views
Why is DefaultModelBinder ignoring custom prefix specified by Bind attribute? [migrated]
In next example DefaultModelBinder will look for any data item called travels and create an array that contains those items:
[HttpPost]
public ActionResult Index(string[] travels)
{
...
0
votes
0answers
7 views
what is the correct way to pass a range of values using “routing table” url format [migrated]
I am learning ASP.NET MVC and it is easy to pass a single value to a view,
using the following url format:
controller/view/id
and in the controller's code, I can simply define the interger id ...