First off, I wouldn't modify the wrapper code. It's purpose is to deal with the generics of a request. You should just use that code by passing along data to set up the specifics of any given request.
Also, if you have working code, then change or add something that breaks it, the error is likely to be in your changes/additions. It might also be that the data you send in the request can't be handled correctly by the server, in which case you have to go have a look server side.
So, start by checking what your browser's debugging tools tell you. My favorite is Firefox's error console along with the Firebug extension. If you get no error message there, check your php error log.