title: AJAX JQuery JSON Post Data not Reaching Controller
body: <pre><code>var url =  base_url+"ajax/user/list_user_info/"+userId;
  $.ajax({
          type: "POST",
          url: url,
          data:{user_id:userId},
          contentType: 'application/json',
          dataType: 'JSON',
          success: function(data) {
  
              if(data.redirect){
                  window.location = data.redirect;    
              }
              else {
                  $('#profile-main-content').html(data.html);
              }    
          }      
      });
  </code></pre>
  
  <p>Now, this is my request, a pretty standard AJAX request. My problem is that this request is not reaching the controller for some reason. To check I have performed a simple test insert in the database to check the result at first line of the controller's function. But the test does not get inserted. The url is correct because i checked the declaration of the base_url. I know I put the "userId" as an argument and passed it as POST data, but this is me just trying desperately. Any Ideas please? Let me know if i was not clear about anything. Thanks.</p>