Q:

JQuery Upgrade and AJAX

I just upgraded to JQuery 1.5.2 from 1.4 and my PostForm is not working now . It does post to page but even though there is no error it says there is error.
function TestPostForm(){
               $.ajax({
                    type: "POST",
                    url: "process.jsp",
                    data: 'operation=Test&ui=TestUser',
                    dataType: "application/x-www-form-urlencoded",
                    async: false,
                    success: function(response) {
                        alert('Success');
                        return response;                    
                     },
                         error: function(xhr, ajaxOptions, thrownError) {
                              alert("There was an error : " + xhr.status);
                       }
                    });
              } 

Java Code : process.jsp
if (operation.equals("Test")) {
            String ui = request.getParameter("ui");
            out.println("Ok" + ui);
        }

A:

Your problem is with dataType, what you should have defined was contentTypeString:
contentType: "application/x-www-form-urlencoded"

dataType defines what type of data you expect your script to return (xml, json, script or html) while contentType passes the type of content you are sending in the request.
You can read more about these options on the jQuery API: http://api.jquery.com/jQuery.ajax/

