Ajax Request with jQuery not happening

I solved my problem after a long time struggling, that’s why I think I should list some tips for someone with a problem like this:

  • If you change your javascript file, use ctrl+f5 to force reload the page
    and the resources. The caching almost got me crazy as I changed the
    file and the changes didn’t take place.
  • Use your browser’s network analisys tool. In chrome, hit f12 and go to the ‘network’ tab. Make your submission and click to see the details. Firstly, I couldn’t see
    what the server was responding and that tool helped me a lot.
  • Use wp_send_json_success( $data ); in your admin-ajax.php and set
    dataType : 'json' on the ajax call.
  • Create the actions for users that are logged in users, and for users that aren’t. If you forget to create the action, it may not work. In my case, it was the line: add_action("wp_ajax_nopriv_my_delete_object", "my_must_login");

This guidelines would have spared me some hair! 🙂