Welcome Guest, Not a member yet? Register   Sign In
Throw Exception From AJAX Call
#4

[eluser]craigkoster[/eluser]
Thanks for the info, Brian. I suspected that was the case. I was previously just returning JSON with a success flag which I was checking in my AJAX call (e.g. if success then do this otherwise show nice error). I thought that maybe it'd be cleaner to use exceptions but it looks like I'll have to just switch my catch{} blocks to take the exception and format ->getMessage() to JSON in order to return it to my AJAX call.

Thanks again for the info.

Craig


Messages In This Thread
Throw Exception From AJAX Call - by El Forum - 09-25-2009, 12:21 PM
Throw Exception From AJAX Call - by El Forum - 09-25-2009, 12:38 PM
Throw Exception From AJAX Call - by El Forum - 09-25-2009, 02:55 PM
Throw Exception From AJAX Call - by El Forum - 09-25-2009, 03:17 PM
Throw Exception From AJAX Call - by El Forum - 09-28-2009, 07:31 AM



Theme © iAndrew 2016 - Forum software by © MyBB