when deleting record from DB the page cannot be rediirected using AJAX |
Code: View Code: Controller Code: Model PHP Code: redirect('users/upload','refresh'); There you go again using capital letters when they should be lowercase. What did you Try? What did you Get? What did you Expect?
Joined CodeIgniter Community 2009. ( Skype: insitfx )
An AJAX response sends all output to the AJAX success callback.
What you need to do is use the "status" property as returned to success to decide what action to take - in your case a redirect via JavaScript. Assuming you're using JQuery, the JS looks roughly like this... Code: success: function(data) In case it's not clear, remove any redirect calls from the controller method |
Welcome Guest, Not a member yet? Register Sign In |