Delete Item / Job from Database - CodeIgniter PHP |
Hello, I've posted a pretty involved post about not being able to delete an item (job listing) from a database on an app using Codeigniter. If anyone can help, here's the link:
http://stackoverflow.com/questions/43506...9_43506919 Thanks Steve
I think it is because it is related to your job which you get paid to do. Asking strangers to fix your work that you get paid to do won't yield results. You will probably still get an answer, but certainly be mindful of that in the future. It is disrespectful.
Your code is not difficult. If you run into issues and have spent N amount of hours trying to figure it out, take a break and walk away from it for a little bit. Run through the logic. In your case, the delete functionality wasn't working, so I would start at that method and understand all of the variables/functionality in question.
It's also good to add debug log messages throughout your code, in all functions down the stack (from controller, to model, to library or wherever it goes) so you can see if the app is doing what it's supposed to, and if not, you can see where it stops/derails.
You can do this with CI's log_message function: http://www.codeigniter.com/userguide3/ge...og_message If it's not getting stopped anywhere, try logging the parameters passed, and the result returned from the delete function to make sure the correct ID is passed along and to see if the delete query is running etc. |
Welcome Guest, Not a member yet? Register Sign In |