asp.net mvc 2 - Error during redirect to MVC Mobile Area using 51Degrees.mobi -


i'm relative newbie mvc. app i've written works , continually fine tune learn. recently, i've been toying mobile web site tools. i've never needed did searching/reading/tinkering could. started microsoft web app toolkit ended being bit outdated kept on reading , switched using 51degrees.mobi library.

i've set based on several different posts:

  1. steve sanderson - http://www.asp.net/learn/whitepapers/add-mobile-pages-to-your-aspnet-web-forms-mvc-application
  2. 51degrees user guide - http://51degrees.codeplex.com/wikipage?title=user%20guide
  3. ...and bunch of other sites , descriptions centering around same basic points.

so here's have described mr. sanderson.

  • created mvc area mobile controllers/views in turn created mobilearearegistration.cs file

area - mobile

  • modified mobilearearegistration.cs under area specify default controller , action.

enter image description here

  • included 51degrees components in config file. namely sectiongroup references, fiftyone section include redirect , httpmodule. enter image description here

i have use following iis module debugging though i'm using win7: enter image description here

i've made necessary modification global.asax.cs file include primary namespace there's no confusion app area should default when executing. (as identified in steve sanderson's post).

lastly, i've installed iphone emulator , android emulators , code redirects in homecontroller. don't have specific yet each device. i'm still trying redirect kick in properly.

enter image description here

when run site in desktop browser (no mobile redirect) runs fine. when use emulators (or try direct desktop browser mobile site) following error. sure seems obvious (missing controller) it's there. not seeing?

the requested page cannot found. (404)

system.web.httpexception: controller path '/mobile' not found or not implement icontroller. @ system.web.mvc.defaultcontrollerfactory.getcontrollerinstance(requestcontext requestcontext, type controllertype) @ system.web.mvc.defaultcontrollerfactory.createcontroller(requestcontext requestcontext, string controllername) @ system.web.mvc.mvchandler.processrequestinit(httpcontextbase httpcontext, icontroller& controller, icontrollerfactory& factory) @ system.web.mvc.mvchandler.beginprocessrequest(httpcontextbase httpcontext, asynccallback callback, object state) @ system.web.mvc.mvchandler.beginprocessrequest(httpcontext httpcontext, asynccallback callback, object state) @ system.web.mvc.mvchandler.system.web.ihttpasynchandler.beginprocessrequest(httpcontext context, asynccallback cb, object extradata) @ system.web.httpapplication.callhandlerexecutionstep.system.web.httpapplication.iexecutionstep.execute() @ system.web.httpapplication.executestep(iexecutionstep step, boolean& completedsynchronously)

a second set of eyes grand! in advance assistance.

answered!

the issue wasn't configuration of mobile tools , redirection rather namespace of mobile section in area itself.

my namespaces in mobile area controllers licensing.web.mobile.controllers. needed licensing.web.areas.mobile.controllers.

once added "areas" namespace worked champ.

i found bit more digging: asp.net mvc 2 , 404


Comments

Popular posts from this blog

linux - Mailx and Gmail nss config dir -

c# - Is it possible to remove an existing registration from Autofac container builder? -

php - Mysql PK and FK char(36) vs int(10) -