Welcome Guest, Not a member yet? Register   Sign In
autoloading helper library model breake ajax json
#1

Hy, i am facing a really strange issue when using the autoload.php file.

if i use the $autoload['helper'] = array('myOwnHelper'); inside the config/autoload.php and i make a jquery ajax request, the json isn't render (no object show in console.log ).

But with the same ajax and the loading made inside the controller with $this->load->helper('myOwnHelper'); tadam, all worke fine as it must do (the problem is the same whith autoloading my own model).

Someone have see this stuff before? I had this behavior since CI2, it's not new.

The only manner i have found to bypass this it's to render the request as html, then trim the response Dodgy  which is terribly ugly and not really compatible with some jquery lib.

The other solution it's to load at each page helper and model who normally must be globally initialised.

Any help would be appreciated it's since days i try to solve this feature

ps: i have join an image of what is passing because i am not so sure of my english for the explanation Blush

Attached Files Thumbnail(s)
   
Reply


Messages In This Thread
autoloading helper library model breake ajax json - by lanoux - 01-20-2016, 09:35 AM



Theme © iAndrew 2016 - Forum software by © MyBB