Solved

asp.net mvc web api - mobile views

Posted on 2013-11-11
8
486 Views
Last Modified: 2013-11-25
Is it possible to use asp.net wep api and return two different views based on the device (mobile/desktop)?

Looking for some built in feature.
0
Comment
Question by:sudheer_k
  • 3
  • 2
8 Comments
 
LVL 21

Expert Comment

by:Craig Wagner
ID: 39640348
ASP.NET Web API doesn't return views, it returns data (XML, JSON, etc).

Did you mean ASP.NET MVC?
0
 

Author Comment

by:sudheer_k
ID: 39640841
Oh ya. That should work fine.
0
 
LVL 26

Accepted Solution

by:
EddieShipman earned 500 total points
ID: 39663040
There was a great article in MSDN magazine about using ASP.Net4 to create mobile-optimized views using WURFL.

Part 1: http://msdn.microsoft.com/en-us/magazine/dn296507.aspx
Part 2: http://msdn.microsoft.com/en-us/magazine/dn342866.aspx

He had an earlier article on
"a server-side approach to take with ASP.NET MVC site development: to build ad hoc views for each class of supported devices (“Mobile Site Development: Markup http://msdn.microsoft.com/magazine/jj133814)"
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 

Author Comment

by:sudheer_k
ID: 39675107
Thanks. This looks fair to me.
0
 

Author Closing Comment

by:sudheer_k
ID: 39675109
Thanks. This is good.
0
 
LVL 26

Expert Comment

by:EddieShipman
ID: 39675767
Which did you end up using?
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

I found this questions asking how to do this in many different forums, so I will describe here how to implement a solution using PHP and AJAX. The logical flow for the problem should be: Write an event handler for the first drop down box to get …
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
Viewers will learn about basic arrays, how to declare them, and how to use them. Introduction and definition: Declare an array and cover the syntax of declaring them: Initialize every index in the created array: Example/Features of a basic arr…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now