Return Custom Error Using .post

Return Custom Error Using .post

Ok, so having trouble finding my answer because I'm not sure what to search for. I know how to POST to my PHP script, but I want that PHP script to return a custom value back to my original page.

I'm doing come credit card processing, and I want to return the status (declined, approved, etc). This return status would determine what my .slideUp function looks like.

I hope I'm making sense?

Please help :)