Is there an error ticket? I notice you're returning a dict, so web2py will attempt to find and execute a view (in this case, a .html view, as you have specified no extension in the URL). However, if there is no view and the generic view hasn't been enabled, you would get a 404 response, not a 500.
Anthony On Wednesday, June 15, 2016 at 9:24:38 PM UTC-4, wdtnh wrote: > > The problem is that I get nothing back? I'm getting an http error 500 > internal server error. > > On Wednesday, June 15, 2016 at 5:10:50 PM UTC-4, Anthony wrote: >> >> What exactly is the problem? What do you see in the browser network tab >> (i.e., request and response details) and Javascript console (any errors)? >> >> On Wednesday, June 15, 2016 at 4:34:18 PM UTC-4, wdtnh wrote: >>> >>> I would appreciate any insights anyone might have on what I'm doing >>> wrong here. For now just trying to get a simple REST GET request to work >>> At this point, I'm simply trying to get some data where the param is >>> hard coded. >>> >>> Any help would be extremely appreciated. I'm not sure if my $.get is >>> wrong or is it my controller method. >>> >>> In my controller: >>> >>> @request.restful() >>> def testRESTGET(): >>> def GET(): >>> id =1359 >>> account = db.account(id) >>> return account.as_dict() if account else None >>> return locals() >>> >>> in view: >>> >>> function ajaxGet() { >>> $.get( "http://localhost:8000/myApp/accounts/testRESTGET" ) >>> .done(function( data ) { >>> alert( "Data Loaded: " + data ); >>> }); >>> >>> >>> >>> -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.