Welcome Guest, Not a member yet? Register   Sign In
debugging javascript in a view
#8

(This post was last modified: 01-20-2018, 01:56 PM by jreklund.)

You need to have two functions inside your controller. I have a separate index and json function.
You put everything inside org_chart_management and that's not going to work. Now it's echoing your html out as json.

You also have your url wrong in the ajax.
Code:
var jsonData = $.ajax({
  url: "/index.php/configure/json", // Here is the second function that you forgot to create
  dataType: "json",
  async: false
}).responseText;
Reply


Messages In This Thread
debugging javascript in a view - by richb201 - 01-19-2018, 02:25 AM
RE: debugging javascript in a view - by jreklund - 01-19-2018, 03:28 AM
RE: debugging javascript in a view - by richb201 - 01-19-2018, 06:22 AM
RE: debugging javascript in a view - by jreklund - 01-19-2018, 06:48 AM
RE: debugging javascript in a view - by richb201 - 01-19-2018, 06:35 PM
RE: debugging javascript in a view - by jreklund - 01-20-2018, 06:20 AM
RE: debugging javascript in a view - by richb201 - 01-20-2018, 09:10 AM
RE: debugging javascript in a view - by jreklund - 01-20-2018, 01:55 PM



Theme © iAndrew 2016 - Forum software by © MyBB